Hi KosalaRandika-9232,
You can try the following command to prevent this from happening:
appcmd.exe set config -section:system.webServer/serverRuntime /alternateHostName:"DESIRED ALIAS" /commit:apphost
-------------------------------------------------------------------------------------------------------------------
--If the reply is helpful, please Upvote and Accept as answer--