Hi, I am Dave, I will help you with this.
If those are pre-installed OEM licence keys, they cannot be used on other PC's, those licences are locked to the original motherboards.
Also, if those are full retail licences, the original owners of those licences may have used them on another PC, then you cannot use those licences.
Donwload the free ShowKeyPlus app from the Microsoft Store, then click Check Edition on the left of that app and you can check what type of licences those keys are for.