Summary
There are many different fasteners used in automotive applications,
including screws, bolts, studs & nuts. Washers & chemical
compounds can be used to help secure these fasteners.

Screws are generally smaller than bolts and are
sometimes referred to as metal threads, they can have a variety of
heads , they're used on smaller components, and often their thread
extends right from the tip to the head so they can hold together
components of different thickness.
Different screws can be tightened with a range of tools.

An Allen head screw has a recess for an Allen key. It’s sometimes called a cap screw. It usually screws into a hole rather than a nut, and it needs tightening with an Allen key.

A machine screw has a slot for a screwdriver.

Bolts are always threaded into a nut or hole that has an identical thread cut inside.

There are a number of special screws cut their own threads as they go. This is called tapping a thread and pictured above is a self-tapping screw. It's made of hard material that cuts a mirror image of itself into the hole as you turn it.

This is also known as a self-tapping screw but it’s designed for cutting and holding thin sheet metal, so it is often used on car bodies.

Bolts are often bigger than screws, and are used for heavier jobs. They nearly always have hexagonal heads that only fit spanners.
Torx drivers are used with for torx bolts and are often found in vehicle engines where a particular need for fastening is required.
Often, the thread on a bolt is only as long as it needs to be to tighten onto the nut or into the threaded hole.

A stud is like two bolts in one, for instance, an
exhaust manifold on the cylinder head is normally located and held by
studs and nuts.
Studs can have different threads on each end. On one end ,
there’s a thread that's best for gripping the hole in the cylinder head
and to locate the exhaust manifold onto, and on the other end there’s a
thread for pulling everything together tightly with a steel nut.
Nuts are often used with bolts. A nut is a piece of metal,
usually hexagonal, with a thread cut through it. There are many
different ways to keep it done up tightly.

A self-locking or Nylock nut can have a plastic or
nylon insert. Tightening the bolt squeezes it into the insert where it
resists any movement. The self-locker is highly resistant to being
loosened by the kind of vibration that engines and vehicles experience.
Tightening this style of nut distorts the insert, so it only
provides its locking effect the first time you use it. If you remove the
nut, it should be replaced with a new one.

A Castellated nut has slots like towers on a castle.
When it's screwed onto a bolt that's been drilled in the right spot, a
split pin can be passed through them both and then spread open to lock
the nut in place.

A speed nut isn’t as strong as the others but it can
be a fast and convenient way to secure a screw. Once the speed nut is
started, it doesn’t need to be held.
Some bolts and nuts need washers.
Flat washers spread the load of a bolt-head
or a nut as it’s tightened, and distribute it over a greater area. This
protects the surface underneath from being marked by the nut or head as
it turns and tightens down. Flat washers should always be used to
protect aluminum alloy.

Other washers tackle the problem of nuts working loose through vibration or movement. A spring washer
compresses as the nut tightens, and the nut is spring loaded against
this surface, which makes it unlikely to work loose. The ends of the
spring washer also bite into the metal. Spring washers are used more for
bolts and nuts.

Screws mostly rely on smaller shake-proof washers. The external ones have teeth on the outside, the internal ones - on the inside, and one has both.

Tab washers get their name from these
extensions. After the nut or bolt has been tightened they remain exposed
and are folded up to grip the flats and prevent movement.

Chemical compounds help prevent fasteners
loosening. They’re applied to one thread, then the other is screwed onto
it. This creates a strong bond between them, but one that stays
plastic, so in future they can be separated with a spanner if necessary.
Other compounds can be applied after assembly.
Some metals react with each other and bind together.

Spark plugs can do it when they're in aluminum cylinder heads. An anti-seize compound neutralizes the chemical reaction that can make this happen and it prevents threads and fasteners from sticking together.
Larger bolts and nuts must sometimes be tightened to a
specified level - tight enough to hold components together but not so
tight that the component or the fastener could fail. This level of
tightness is called a torque specification. Bolts and nuts are often
marked to tell you how strong they are, how much torque can be safely
applied to them.

This is a grade 5 bolt - as these markings show.

This is a grade 8 bolt, so it can be done up more tightly without danger of it failing. The dots on this nut give similar information - this is a grade 8.

These are imperial system markings, the metric system
uses numbers stamped on the heads of metric bolts, and on the face of
metric nuts. Even studs have a marking system to make sure they're not
over-stressed when you tighten them.