That is quite true. Actually the IP Lookup sites, use third party data. Their third-party data source isn’t guaranteed to be 100% accurate either. Misentered data and recently moved Wi-Fi routers can also contribute to the inaccuracy of IP data. This site dedicated to information on IP geolocation asked IP data providers about the accuracy of IP data at various levels. They estimate that countries are 95%-99% accurate, regions (states) are 55%-80% accurate, and cities are 50-75% accurate.
However, there is a site https://dnschecker.org/ip-location.php, that uses four geolocation databases, so the user has an estimated location of IP, with the display of location on maps.