A finish time, not a running counter
When you start a session, Just 5min records the exact moment it will end. From then on it does not matter whether the app is open, backgrounded, or shut down by iOS to save battery. The clock the session cares about is the phone's clock, and that keeps going.
Lock it, leave it, take a call
Put the phone face down. Answer the door. Switch to another app to look something up. The session ends when it was always going to end, and tells you — then it is recorded with its length and any mood, tag or note you attached.
The one thing that ends a session early is deleting the app while it runs. Short of that, it finishes.
Why it matters for the habit
"I lost my session, so what was the point" is one of the fastest ways to abandon a new habit. If every session you start reliably lands in your record, the habit has something to stand on. It pairs with a streak that forgives a missed day.