Arkos had it right on the money for the procedure...
The drain plug is pretty big though, IIRC it is either a 23 or 24mm bolt. The fill plug is similar in size....
The manual calls for 2.83 qts. of fluid, so 3 qts. should be all you'll need. Just make sure when you fill it up that you can feel the fluid with your finger through the fill hole. (The fill hole is on the front of the tranny housing.)
The torque specs for the drain and fill plugs both is 29 to 43 ft/lbs. You might want to pick up a new washer from mazda for both while you are at it too...
Good luck!