A requirement for changing habits is changing the physical world. Picking a device with no internet browsing capabilities, like an e-reader or a physical book. Or going for a walk where you physically don't have your phone. Even putting a phone in the next room isn't enough, you have to be somewhere where you physically can't access the phone.
Humans are not capable of fixing attention habits in which the physical world is set up to make it feasible to lose your attention.