A spoiler is just that. A spoiler. It is meant to "spoil" the air, on a car its meant to increase downforce, which is also just as it sounds, force in a downward direction to increase traction and hold a car to the road better at higher speed. On a normal consumer car it is an accessory part. But on higher end sports cars, and race cars, it is a functional part. Their are also front spoilers and rear, with rear being trunk mouted and the front being mounted to the bottom of the front valance or bumper.
also, on an aircraft a spoiler is meant to spoil the airflow and slow an aircraft by increasing drag (which is why theyre also referred to as air-brakes.)