This is a really important question, and it's one that I think most companies don't put enough thought into.
At first blush, most people would probably respond to this question with, "the product team, duh." Engagement and retention are fundamentally product-centric metrics; if engagement and retention metrics reflect poorly on the product, the product team is responsible for addressing that, so obviously the product team owns those metrics -- right?
But this isn't a productive, modern way of thinking about product / market fit, engagement, and user satisfaction. The product team "owns" the development process, but the marketing team controls the stream of users that enter the app: an incompetent / self-hating marketing team could onboard wholly inappropriate traffic to the app to tank engagement metrics and the product team would have almost no recourse. That'd be an extreme case, but clearly there's some overlap in responsibilities around engagement metrics between the marketing and product teams.
If you accept that paid user acquisition is the growth engine of mobile apps, then you accept that marketing and product are both essentially equally reponsible for an app's success: if the two teams don't tightly coordinate their efforts and operate inside of a positive feedback loop, it's difficult or impossible to scale an app. Marketing needs to lean into the product's strengths and the product needs to adapt to the realities of the marketplace.
What I mean by that is: the marketing team knows who it can reach, so shouldn't the product be optimized for those user segments? If the marketing team thinks the product concept resonates best with women aged 18-34 and the product is being optimized for middle-aged men, a massive barrier to product / market fit exists. Imagine if TikTok started building a dedicated video stream for learning to code, or if Calm added a dating feature. These features aren't aligned with product identity, which directly influences the demographics that the products resonate with. If the product teams at these respective companies built these features and demanded that the marketing teams at those companies changed their targeting to reach people for whom those featured would resonate, marketing campaigns would break completely.
In practical terms, this means that the marketing team helps the product understand the users for which the product best resonates. And in a reporting context, this means that the marketing team is responsible for ROAS and not just spend in a general sense. If there's no monetization component to the way that the marketing team's work is evaluated, the relationship between the marketing and product teams can turn combative / contentious, which isn't good for anyone.