They would only need to use the API to communicate with other fediverse instances. They could make a proprietary API for their mobile client, which would display ads.
But that's beside my point, which is that no one will bother to reverse engineer their app if there are easier ways to avoid ads (like setting up your own instance). Their users will be people who want a turn-key solution. People who are allergic to ads (like me) will be better off setting up their own server or using a smaller server, or paying for "premium" access to a commercial server.
At least, that's how I see the fediverse evolving. I've only been here for about a week, though, so take my opinion with a big grain of salt. It'll be interesting to see how this plays out.