First log on to Minecraft.
Spawn in or find a wolf. Make sure you have bones with you.
Keep right clicking with a bone until hearts pop up and a red collar appears around the dog's neck.
That's all. Your dog will follow you around until you tell him to sit and will fight off monsters! Keep placing blocks!