There should be PHP sscipts; DoH servers. Install it to your https web site. Use it as a proxy to another DoH server. But before you forward the query to the other end check the domain against your black list.
Or you can use ads blocking DoH server https://blahdns.com