Hi, David. I'm Robinson, and I’m happy to help you today.
Running the activation troubleshooter and selecting the option "I changed hardware on this device recently" should fix the problem and activate your computer.
1-Select the Start button, then select Settings > System > Activation > Troubleshoot. The troubleshooter will show "Windows can’t be activated on your device'.
2-Select "I changed hardware on this device recently", then select Next.
3-Enter your connected Microsoft account and password, then select Sign in. The troubleshooter will only work with the connected Microsoft account.
4-From the list of devices that are linked to your Microsoft account, select the check box next to "This is the device I’m using right now". (Note: Here you will need to select your old computer name in the list)
5-Select Activate.
If the problem persists, please attach a screenshot of the error code that you receive when you try to activate Windows to help identify what is causing the problem.
You can see at this link how to include a screenshot in your post.