Here is how I do it. First, your horse needs to be used to a stud chain under the chin and know how to back up and step forward. To teach side passes and pivots is necessary that your horse be able to disengage the shoulders or hips as you request. Second, DO NOT TOUCH YOUR HORSE. You can't touch the horse in the obstacle or showmanship class so don't get in the habit at home when practicing. Third, use some sort of pole laying on the ground so you have a visual of where to keep your horse's feet.
Now, that you're set up. Lead your horse over the pole with the front feet in front and the back feet behind. Stand in front of or to the left side of your horse. Lift up on the chain and with the chain, push your horse's front end away from you (this will swing the back end towards you) saying "side". Release and praise the horse when they move over (even if just an inch). Now, take one step towards your horse's hip and gently pull their head towards you so their hip moves away from you (release before their front end steps towards you). Now, they should be lined up fairly straight. Repeat until you side pass over the entire length of the pole. Its important to remember every time you ask the front or back end to move away that you release the pressure on your chain for a reward.
To sidepass to the right, hold your hand on the left pulling away from you and stand in front of or to the right of your horse. Use the same steps as above going to the right. With practice, you'll be able to stand just barely off to one side or the other, and with a small tug of your stud chain have your horse side pass in either direction.