This is the latest question on posture I've answered on the Quora platform, where people ask the general public about anything and everything:
What is the most efficient way to avoid slouching from the usage of phones?
Use your awareness. Phones are inanimate objects, they don't make you do anything, your behaviour is the key.
Assuming you have adequate eyesight, the reason you slouch towards your phone is that we follow our attention physically, and the more you concentrate on the phone, the more that you will be drawn towards it, the more you will lose sight that you are performing a physical activity and lose the ability to self correct.
It's not a matter of multitasking, but of allowing yourself not to be drawn into the phone, to have agency, and not let yourself be bossed about by inanimate objects. It's a matter of widening your awareness so that it's more inclusive, being present to yourself in physical activity. It's about thinking. By thinking, you can be more efficient. If you're not prepared to think, you can't have agency, you can't be the boss, only the victim.
The way the question is framed is interesting too, "how to avoid", because it correctly implies that you don't need to do, or hold, your posture correctly, just not interfere with it. In Alexander Technique terminology we'd say you want to inhibit your habitual reaction to using a phone. It's about what you don't do! When you're poised, which is as much an attitude, your posture will do itself without interference.