Apparently a non-profit can own all the shares of a for-profit
You can imagine a non-profit buying enough shares of a for-profit company that it can appoint the for-profit company's board of directors, at which point it's a subsidiary.
Heck a non-profit is even allowed and encouraged to make a profit. There are certainly rules about what non-profits can and can't do, but the big rule is that a non-profit can't distribute its profits, ie. pay out a dividend. It must demonstrate that their expenditures support their tax exempt status, but the for-profit subsidiary is more than welcome to pay out dividends or engage in activities that serve private interests.
This works when there's an obvious non-profit that has a monetizable product. The latter conflicts with the former, so it requires a disconnect. Meanwhile, if Apple tried to do the same, investors would look at that as obviously shady. In addition, non-profits are more heavily restricted by the government.
Lastly, you can't just "take the money" and "do what you want"; fraud, malfeasance, fiduciary responsibility (in the corporate entity), etc still exist. It's not some magic get out of jail free card.
It was a "legal fiction" to sidestep union rules, government employment regulations, etc...
This let them hire IT staff at market rates, because otherwise they couldn't pay them a competitive wage as normal public servants working directly for the departments.