The Windows 8 OEM license is transferrable, which is different from the Windows 7 version. But you cannot use that key to upgrade. You need an installed, activated version of 8.1 and upgrade that to Windows 10. When that is done, that configuration is marked as being Windows 10 legal and it may take being logged into a Microsoft account, but still some doubt on that requirement.
So you will probably need to move the Windows 8 license to the new system by calling Microsoft. But as you can see, there is always confusion when it comes to things Microsoft will only explain using Legalese.