yes, if the network does not support name resolution (ping computername does not return the IP-Address), you alternatively can put the names and IP-Addresses in the hosts file.

Please note, that the name resolution must work from the webclient to webserver (and vice versa) and also from the webserver to the server (and vice versa)