An aspirator is a cheap, easy way to generate vacuum suction without finicky and failure-prone electrical hardware. It works because of the Bernoulli effect: Fluid moving through a smooth constriction (i.e. one that produces little turbulence) must flow at a higher velocity, which puts it at less than atmospheric pressure. A hose attached to the area of low pressure flow thus allows gas at any pressure higher than that generated beyond the constriction, including atmospheric pressure, to push its way in. The upshot of this is that one can generate pretty decent suction for chemistry and physics demonstrations with only a source of running water, a specially constructed tube, and a hose with walls thick enough not to collapse under moderate vacuum.

Perhaps a diagram will help:

|        |
|        |
|        |          <---- Water from tap at atmospheric pressure
|        |
|        |
'        '
 \      /
  \    /            <---- Pretend this is a smooth constriction
   \  /
   '  '
   |  |
   |  |
   |  |             <---- Water flows here at higher velocity, lower pressure
   |  |
   |  |
   |  +---|\|\|\
   |      | | | )   <---- Vacuum hose attachment
   |  +---|/|/|/
   |  |
   |  |             <---- Water drains
   |  |

Ideally, an aspirator run with water at 25° C will generate an atmosphere with pressure of approximately 24 Torr, due to the water's vapor pressure. At sea level the air pressure is 760 Torr, so this is much closer to a good vacuum than one might expect. Rotary oil pumps and diffusion pumps may generate 10-3 or 10-6 Torr respectively (and more esoteric pumps go even lower), but the aspirator is still hard to beat for reliability and cost.

To use an aspirator, one generally wants to run the vacuum hose first through a secondary reservoir, since if the water is turned off the remaining low pressure will draw drainage water through the hose. For drying precipitated chemicals, the hose is attached to the side of a filter flask, and a Büchner Funnel attached with a stopper in the top. After the precipitate has been deposited on the Büchner's filter paper, air is drawn through it until the precipitate is dry. Aspiration is also great for boiling off solvents with little or no additional heat added that might destroy a fragile organic solute -- for reference, water will boil at 50° C under aspiration, and ethyl alcohol will boil at room temperature. One physics demonstration I've seen online used an aspirator attached to a big steel drum. As the drum's internal pressure was brought down to 300 Torr, the atmosphere's air pressure exerted about 13 tons on the drum's walls, crushing it quite handily.