What also helped me a lot is to deactivate notifications of every communication channel ( email, messenger even the phone )
If notifications are turned on, it feels like other people have control over my mental state, because if an incoming email makes a ping it means that the person that just sent me a message caused my focus to shift in the work I am currently doing. Even if it feels minimal this compounds quite a lot over the course of a day.