I think it's great that so many software engineers and developers share their energy and expertise.
I think your perception of what other professions do might be limited by your own experience, though. Just to go in order:
Legal: My aunt is a lawyer and volunteered her time in a legal "clinic" where people with landlord/tenant issues could come in and get advice for free. She also worked some of her professional time on cases where the clients did not have to pay, a practice that is common in the legal industry, called "pro bono."
Engineering: There are a wide variety of student and volunteer activities that are well-supported by professional engineers on a volunteer basis. For example one of my coworkers volunteers his time evenings and weekends to help "coach" a high school robotics team. And you may have heard of various other engineering challenges like popsicle stick bridges or egg drop competitions.
Medical: Several friends have transitioned into working in the medical field through free opportunities, primarily by volunteering with local rescue squads and first responder teams. These teams are typically supported/led by some folks with professional medical training, but anyone can show up, volunteer their time, and get medical training.
Ultimately, to work in these fields professionally, folks need to get a credential of some kind, and that might cost money. That's not true of a lot of software development right now.
But I think that is primarily because computing is such a young industry right now. All industries start out that way. There were times in history when you did not need a credential to work with the law, or to design machines, or to treat illness.
But as these professions had a larger and larger impact on society, society imposed higher and higher expectations on practitioners... expectations which required more formal structures to satisfy.
I predict the same thing will happen to computing technology, at least at the high end. It's already true in some areas like life-critical embedded systems. You're not going to get a job writing code controlling the ISS after doing some free online tutorials.