This gist explains how to setup DOH for Firefox using dnscrypt-proxy and nextdns.io.
Get a Linux server with a static IP (DO droplet would work). Download and install dnscrypt-proxy.
Edit dnscrypt-proxy.toml
(see wiki):
[local_doh]
listen_addresses = ['123.456.789.1:3000']
path = "/dns-query"
cert_file = "fullchain.pem"
cert_key_file = "privkey.pem"