Remove the two small bolts from the broken latch mechanism, using a Phillips-head screwdriver. The bolt heads are on the indoor-side of the door.
Remove the latch mechanism from both sides of the door.
Hold the new parts of the latch mechanism in place on the door with one hand.
Put the bolts back through the indoor side of the latch mechanism, using the other hand. Partially tighten the bolts.
Ensure both sides of the mechanism are in the proper position on both sides of the door, then tighten the bolts.