When you press down on the brake pedal, it activates a plunger in the master cylinder. This forces brake fluid through the system which, in turn, applies pressure on the other brake components. These are forced against the wheels and slow your car down.
There are two main types of brakes: disc brakes and drum brakes. Most modern cars use disc braking systems on the front wheels and drum brakes on the rear, while older cars use drum brakes on both the front and rear wheels.
Disc brake systems have two pads per wheel. These clamp down on the brake disc when the pedal is depressed. Pressurised brake fluid sends a plunger in the calliper forward, forcing the brake pads to squeeze either side of the brake disc. This slows your vehicle down.
Drum brakes work the same way, but use braking shoes instead of pads. These are stored in the steel brake drum itself and, when pressure is applied, the wheel cylinder expands. This component forces the brake shoes apart and towards the inside edge of the drum.