Provided that a person travels within the EU, what is the purpose of verifying the passport? I presume that the company just needs to be sure that I use my own ticket. So why do not they accept a driver's license, for example? Or some other kind of ID?
Airlines ask for a passport, but they don't expect you would necessarily have a passport. They are asking for a travel document of which passport is an example. Most if not all airlines have conditions of carriage, in which they define which travel documents are valid, but at least in the EU an identity card is accepted. If you want to know more specifically about a certain airline, I would recommend you to read their conditions of carriage.
Specifically to EU, companies are not required to check travel documents, but many still do. This is especially typical to low cost carriers as legacy airlines don't tend to check them as often.
I fell in the same situation a year ago. I showed my EU driver's license at check in desk but was refused checking in because the clerk stated that
driver's license does not show nationality. Then I gave her my national ID card and everything was ok.
First, the question "please show me your passport" is likely a mantra as stated by @Lassi. Just like when you are checked tickets in a bus but officers ask you to show
passes, please (in the sense of the monthly/seasonal pass used by frequent commuters).
Anyone can get a driver's license in any EU country regardless of his/her nationality. So the driver's license can never be accepted because does not prove EU citizenship. Only the ability to drive a motor vehicle of corresponding EU category.
Now to Schengen agreement: while it is commonly called to be "no borders" (and no checks) between countries, mind that freedom of circulation in Schengen space is a right granted only to Schengen citizens. So you basically have to prove the airline that you are a Schengen citizen to travel the Schengen area.
That is what was told me.