When you use the Internet in any way, you are using something called DNS (Domain Name System). Here is a typical definition of DNS:
Short for Domain Name System (or Service or Server), an Internet service that translates domain names into IP addresses. Because domain names are alphabetic, they’re easier to remember. The Internet however, is really based on IP addresses. Every time you use a domain name, therefore, a DNS service must translate the name into the corresponding IP address.
You don’t need to remember all that. What DNS your Mac uses involves speed and security. You do not have to accept the Default DNS built into the MacOS. You can use a third party DNS like Cloudflare. The Cloudflare people offer free DNS settings that are the fastest around and very secure. I use them on my Mac and I can attest to it’s speed for sure. This article provides a lot more information about Cloudflare DNS. I urge you to read it and use their DNS settings.