I never go out to specifically teach my horse 'ground manners' they learn just by day to day handling - done correctly.
I insist on manners at all times and always say it is the little things that count and the major rarely happens.
If I am in a stable with a horse I insist that it moves over if I walk to the other side. Right from the start I insist that when I walk into the stable they move back, and if the door is open they wait until I tall them before they make a move to go out.
I do a lot to them when they are untied and they have to stand still. Half a step forward and they get corrected and made to move back.
They ;learn from youngsters to respect my space. Older horses that are mannerless have th crap frightened out of them - usually this is at feed time when they barge and demand their feed, they get it still in the bucket wrapped around their faces if they are really bad and I will continue to chase them backwards around the stable until they show signs of submission. They are then free to eat their feed from wherever it is in their bed. One dose of this and they know exactly where they stand with me. This sort of horse will bullied in all aspects of me handling them until they are trying their best to please then they get lots of praise.