Entries in Hosts file or in custom hosts file ignored

Dear all,

I am desperately trying to blacklist some urls via the hosts file. I used a custom one as well as the original on. Either one entries get ignored somehow. I read the internet but I could not find a viable solution. Any suggestion or further information request are highly appreciated.

THX

https://doc.turris.cz/doc/en/public/dns_knot_misc#adding_static_address_records