The "opening" for light to travel out of a flashlight is circular. Why does the light shine on the objects the flashlight is pointed at over a much larger surface area than the surface area of the aperture? Why doesn't it just illuminate the whole room or wherever the flashlight is?
Light is a wave , an electromagnetic wave classically. When leaving a point source a wave expands isotropically in angle, spherically, and its intensity falls like 1/r^2 where r is the distance from the source
If a point source lamp is set in a room, it will illuminate spherically all of it, as happens with the lamps hanging from the roof.
A flash light has two extra hardware. The light from the point source is focused with a lens that focuses the point source ahead, i.e. does not allow light to disperse spherically . The other is the aperture that also constrains the start of the dispersion of energy to a beam.
Even without the lens the light would start dispersing spherically from the aperture. The lens concentrates the intensity to a beam.