How to change Hostname in Windows?

Log in to your Windows server via Remote Desktop (RDP).

Open the "Server Manager." In the "Server Manager" window, click on "Local Server" on the left sidebar.

In Local Server Under the "Properties" section, you will see the server's current computer name. Click on the computer name.

In the "System Properties" window that appears, click the "Change" button.

In the "Computer Name/Domain Changes" window, enter "Any hostname as per your choice" in the "Computer name" field.

Click "OK" to apply the change. You will be prompted to restart the server to apply the new hostname. Click "OK" to restart the server.

After the Windows server restarts, its hostname will be "your hostname."

Please note that changing the hostname may require a system restart to take effect on both Linux and Windows servers. Be sure to schedule a maintenance window for any necessary server reboots.