This is because all your traffic is going out the wireguard interface. You have to use a DNS server that can be reached through the tunnel and not local. Otherwise you have a potential DNS leak situation.
You are only going to “leak” dns if you set DNS that is not proton. And im saying “leak”, because from proton perspective, anything that is not their DNS is considered leaking which is not really true. From your perspective, if you are not leaking DNS from your ISP, there is no DNS leak. To test it, go here and scroll down and check the DNS Addresses field. As long as you dont see your ISP`s DNS in that list, you are not leaking and everything is fine.