In the small company I work we have a few company smartphones connected to internet only via WiFi.
If during a call someone walks during and the smartphone changes access point, nothing happens and the call continues normally. But if said thing happens while the smartphone is in standby, the proprietary VoIP client will just disconnect and result offline. It will try to re-go online only when opening the client.
I already contacted the VoIP provider and tried all the discussed solutions, and now I suspect it has to do with how Android handles WiFi and battery saving.
To make sure I missed nothing here I am.
Edit: battery optimizations for the app are disabled
Edit 2: this was the problem, as indicated by Petr Havel