Id have to write a book to really explain it and guarantee any success, but a lot of it just boils down to rewarding wanted behavior and gently punishing unwanted behavior. I’m a big fan of clicker training. If you arent familiar Id suggest reading up on it. (Youtube is a great source of info on this and all dog training topics) Using the clicker allows you to train longer without overusing treats...aka getting them fat. Once they see the clicker as a legot reward, use treats as a “jackpot” for very good or consistently good behavior.
Basic obedience training helps A LOT. But you dont have to go to the boring-ass classes, just youtube how to train sit, stay, down, rollover, come, heal, post, drop it, etc.
When I say “gently punish,” they pick up very well on vocal cues. They know your happy voice and your mad voice. A stern “bad dog” in your angry voice goes a long way, but only if they know why youre using your mad voice, and that they would be getting rewards if you werent mad. One of the best forms of gentle punishment is taking their favorite toy away.
Also, its very cliche but “a tired dog is a good dog.” If your dog is bothering you, take his favorite toy away, or the one he happens to be playing with, then give him a simple task you know he can succeed, like practicing tip #1 for a while. Then reward him by giving him his toy back and playing with him until he’s tired out a bit, then go back to the obedience training.