This actually depends. Given that on the web, an active Internet Connection is required. Meaning, that if you try to invoke: /logout or /exit.php, or any of website resource, you'll end up with a "Server not found" message or on mobile you might see a "No Internet Connection" message. This means that the file e.g. a logout.php cannot be accessed, leaving you still logged-in, because the PHP (or any back-end responsible code) cannot execute and make sure the user gets logged out. If this is solely a app for mobile, then internal code executing mobile-side will take care of the logout, eventually, the real-time API on the webserver, will discover that communication has died between this user and the platform, and eventually kill the session.
See this as well: Logging out of mobile app without Internet connection
TO add more, some services and platforms, e.g. Spotify work offline (airplane mode), meaning, you can logout or login and play your favorite music and songs from your personal lists. Once online, the app reconnects and checks for any updates or anything that might be useful.