This is working less and less in my experience. Most people are serving ads through the same domain they server content from so the Pihole can't figure out what's an ad and what's content so it lets it all through
Even when it does work you can end up with an empty box where the ad should be, still covering content, still with an infinitesimally small X to close the empty box.
I think part of the problem is a lot of these free games give you bonuses for watching ads. Then the ads they show are awful. And once you watch one ad, it downloads all the ads for when they can’t load.
I think the only real answer is to have some willpower and don’t play the games with awful ads.
Pihole on your network will block those. I use apps and games on my phone and then leave my house and get surprised at how many ads I didn't know where there.
Look into setting up WireGuard or tailscale depending on what you have available to you. I’m always on my home network, blocking ads, thanks to my own VPN.
I don't have any app with embedded ads on my phone. All my apps is FOSS except banking apps. And when I didn't know about the existence of F-droid, I just downloaded patched apks with disabled ads or patched apps by myself using luckypatcher.