I’ll cut to the chase to tell you how to configure your devices to use
these services before getting into the nitty-gritty of how DNS works
and how these services improve on an insecure and easy-to-corrupt
Go to the article for the how, but …
For the different services, the IP addresses to enter are: Cloudflare:
22.214.171.124 and 126.96.36.199 (see note below) Google Public DNS: 188.8.131.52 and 184.108.40.206 Quad9: 220.127.116.11 and 18.104.22.168
The last 60% of the article is a solid, easy to understand write up on DNS and how Quad9 and Cloudflare (and, to a lesser extent, Google) are trying to address inherent issues and risks them without a complete redesign (see the last section in the article).
Nevertheless, every step you take toward greater security and privacy is a positive one. It’s important to think about where your data ends up, and only you can decide whether having your queries available to Cloudflare, Google, or Quad9 is an improvement over your existing exposure to your ISP, which may not employ any of the above mitigations.
Full Disclosure: I work for IBM, a founding member of Quad9.