You do not tell us what type of License you have.
If the Laptop/Computer came with the Windows Operating System preinstalled (Dell, HP, Acer, etc) , that Product Key that came with the Laptop/Computer is for the preinstalled OEM License and is non-transferable.
The OEM License/Product Key (preinstalled Operating Systems on Dell, HP, etc machines) is tied to the first machine it is installed on and dies when that machine dies.
The above rule also applies to OEM System Builders Licenses.
Retail Operating System License, that you buy and install yourself, are allowed to be transferred to another machine.
But Retail Licenses can also only be installed on one machine at any particular time.