As a work around, (assuming a Standard edition activation) mght also try using a kms key as intermediary step.
Dism /online /Set-Edition:ServerStandard /ProductKey:VDYBN-27WPP-V4HQT-9VMD4-VMK7H /AcceptEula
https://learn.microsoft.com/en-us/windows-server/get-started/kmsclientkeys#windows-server-ltscltsb-versions
then if successful use your own product key below after reboot
slmgr /ipk xxxxx-xxxxx-xxxxx-xxxxx-xxxxx
slmgr /ato
--please don't forget to Accept as answer if the reply is helpful--