Pushing location button navigator should show permission request to be located. Accepting it location is shown afterwards.
Methodology used by navigator to evaluate location depends on our device. Mobile device use to have GPS and it is used to evaluate location when available. It is recognized because of the great accuracy and the altitude. No other methodology provide altitude.
The following methodology in mobile devices is the information received from mobile network which device is connected to. Mobile device knows the antenna which it is connected to and most of mobile network antennas location in the world are registered.
When previous methodologies are not available location is evaluated based on IP address. This location is not precise but valid for most of the applications. Additionally, if there is a wifi network nearby it is possible to know location without connecting to this wifi network. There is a world database of MAC address of wifi networks and their locations.
This database of mobile network antennas and wifi MAC addresses location belongs to Google. During several years Google has obtain a huge geographical information available for internet users.