While difficult, it's often possible to teach children to be content on their own, or playing nearby, at least for longer stretches. The book Hunt, Gather, Parent helped me improve a lot as a parent. First step was not reacting when a spill or mistake or misbehavior happened, just staying super chill and calm. Maybe ignoring or at most shooting a single "look" if it was clearly intentional. I realized kids do want to do good, they just are bad at it. Next was giving freedom, but also more expectations. I stopped constantly commanding and telling my kid what to do all the time. As the commands got less frequent we were both happier and she listened more. When she was going to hurt herself, I'd explain what would happen instead of ordering her. Instead of "Don't touch that!" I say "That will burn you if you touch it". If it's the rare physical danger so severe that I need to protect her, I change the environment or keep an eye on her.