People do this because they don't know any better.
Mapping to \\IP\share doesn't rely on the broadcasts that mapping to \\name\share does, so it will often work. Few possibilities as to why it works. First would be that they have public IPs behind the router. Second would be portforwarding at the router. Third would be static routing tables on both ends of the connection.
If the IPs behind the router are public, they should also be routable, so the internet structure would take care of all of that.
If the ports are being forwarded, it should be obvious as they would be connecting to the IP of the router instead of the actual sharing computer.
Routing tables would show up if you were to type 'route print' in a command window. You would see a route to the private IP on the host side with a gateway of the router on the host side.
The other possibility is that they are running router to router VPN. This would require capable routers on both ends. You wouldn't really see it unless you looked at the router configuration.
Anything other than the last scenerio is very sloppy and dangerous. If you have any input at all in the situation, do your best to get it changed. Best option would be a VPN setup. Router to router would be an option, but recent versions of Windows have native VPN support. Several possiblities without additional capital.
Either way, Microsoft networking needs to be disabled on the internet connected interfaces. Period. Current situation is kinda like parking in a bad neighborhood and taping your keys to the parking meter. Sooner or later, someone's gonna figure it out. Won't be good.