And yet in TSFS, McCoy was clearly familiar with the concept of money when he was trying to buy passage to Genesis.
When it comes to money and economics, Trek wound up with a system that's more complicated than it needs to be.
Yes, because all the other economies around the Federation are based on currency.
It really isn't that hard, as I explained somewhere before in this thread. The Federation has an excessive amount of clean, renewable energy sources, they produce so much energy and use it so efficiently that they don't know where to put it. And then they mastered the technology of turning energy into matter and vice versa. That's the basis for an economy that doesn't need any money and can provide basic services for every single citizen for free. Housing, almost 100% efficient solar panels, replicators, what else do you need to live a healthy life?
There is a currency, it's the Federation Credit. But it's not money, it's energy packages.