I recommend to use Activation troubleshooter and select I changed hardware on this device recently when troubleshooting is completed.
You can also refer this Microsoft support article, that shows how you can reactivate after hardware change:
https://support.microsoft.com/en-us/windows/activation/reactivating-windows-after-a-hardware-change
Let us know if this helps!