Changing hostname of NodeMCU

Hi Team,

As part of my project I would like to change the default host name of my ESP8266 WiFi network available. I am working around ESP8266 Node MCU board.By googling I came to know that the below shown code line should work:
WiFi.hostname("yourhostname");

I have included this line above WiFi.begin(). The Serial.Println () prints the host name as I assigned. But it doesn't make any impact on WiFi devices connected listed at the bottom of the laptop. How can I solve this problem. Do anybody can make a help with right code.

Regards and thanks in advance,
Nelvi John