I need a basic explanation for how headphones work.

I am a beginner to this. I have very little knowledge on drivers and headphones in general. I just want someone to explain me the basic knowledge on how they work and sound stuff. Some stuff I would want to know is something like frequency response and sound stage.

Feb 26, 2019
Although electrical engineers can give very detailed descriptions about headphones/amps/signals, bioengineers have yet to figure out how ear and brain work, which I think is truly the most important part of the puzzle. I can give an example of how solid terms can become elusive without knowing the inner workings. Frequency sounds like an absolute term that people all understand. However, it usually assumes decomposing a signal using harmonics, or sine-cosine waves, or Fourier series. Using basis functions other than the Fourier series results a different frequency spectrum. For example, a sine wave of 1KHz has one peak of 1K on its spectrum using Fourier series, but has infinite bandwidth when using a square wave series for the decomposition. A square wave of 1KHz is said to be so because implicitly we use a square wave series to do the decomposition. Otherwise, it also has infinite bandwidth when Fourier series are used. One might say, Fourier series are used because that's the simple and natural form of physical vibrations. But who can be sure the ears and brains of humans are actually following the pattern?
Feb 24, 2019
headphones, like most other loudspeakers, use a coil of wire (wrapped around a permanent magnet) connected to a 'diaphragm' (like the cone of a speaker) which when wiggled pushes the air back and forth in time to the music. It wiggles due to the rising and falling magnetic field in the coil of wire which opposes the magnetic field of the permanent magnet (to push against). That's it in a nutshell.
Feb 25, 2019
When stuff wiggles between 20 times per second up to 20,000 times per second, our ears perceive this as 'sound'. The number of times that something wiggles (in one second) is called 'frequency', The term 'frequency response' is an abbreviation of 'amplitude versus frequency response'. This is a measure of transfer function, or, how well a device (loudspeaker for instance) conveys all of the frequencies that are asked of it to reproduce. If the device is perfect, all frequencies are conveyed equally (equally in amplitude) from the lowest pitch we can hear (20Hertz) up to the highest (20,000Hertz). The amplitude, quantified by decibels, is then expressed as a plus or minus deviation from perfect reproduction (zero). Most specifications that you see conveniently omit this plus or minus figure, rendering the specification meaningless, by exaggerating the response to be perfect, which it isn't, ever. A real honest spec for a speaker might be, "55 to 18,000 + or - 3dB. This would be a VERY good speaker. Sound stage is not something I'm an expert at, but it is a very subjective description audiophiles like to use to try and make you believe that they can hear something that you cannot due to their 'golden' ears.
Feb 26, 2019
sound stage is a term referring to the perceived separation of sound sources when listening - it's how the "performers" are spread out across your "stage", and it is quite easily appreciated if you listen to pink floyd wearing headphones, really better equipment makes the illusion of live performance much more immersive and yes, it's subjective, like all listening, because no-one else possesses your cochleas and auditory association areas frequency is what bennosteve said ;)