I can think of a few ways, but one doesn't they dont qualify as "in play store" and the others not as "easy"... but mentioning anyway
https://f-droid.org/en/packages/org.jak_linux.dns66/ is a FOSS app that looks like it'd do the job.
Magisk offers "systemless" hosts; apply then module then just edit /system/etc/hosts.
Or you could run your own DNS on another device (i.e. pihole) and connect to it from android: Settings > Network and Internet > Advanced > Private DNS