Apple uses WiFi hotspots (and presumably the corresponding signal strength) to triangulate your position using a data from Apple. Similar to how Google maps a hotspot using their StreetView cars, a 3rd party at one time scanned the area you travelled to and mapped the SSID and probably MAC address of the local hotspots.
Though I don't know if they still do, Apple at one time did not maintain this information internally but sourced it from a 3rd party. Some of the initial privacy concerns about iOS regarded how this information was 'phoned home' to Apple without consent; That is, when your iPod was connected and 'knew' its location, it would also scan the local SSIDs and send them to Apple to improve/update the database.
This data was sourced by Skyhook Wireless.
Based on my own inference from experience (though not 100% sure, and I no longer use an iPod, so even if this was true at one time it may not anymore be so), when you map a route in Maps, it caches the relevant SSID information for the areas to which you are travelling before it goes offline.