But if access is available (vCenter), then you can set the corresponding parameter, and then extract it to the VM via vmware tools.
Or this parameter can already be set (which is unlikely).
Nevertheless, you can try C:\Program Files\VMware\VMware Tools>vmtoolsd.exe --cmd "info-get guestinfo.hypervisor.hostname"