Sorry this is hard for you to understand. I should not have phrased it so simply.
Let’s start with the basics.
Do you understand the difference between the state governments and private entities? 
Google it.

This is the beginning of the code.
18 U.S. Code § 227 - Wrongfully influencing a private entity’s employment decisions by a Member of Congress or an officer or employee of the legislative or executive branch

Assuming you understand, the federal government can legally take away benefits from state governments. They are not private entities. What the governmnet can not do is threaten to take away, in this case, a tax exempt status for not following a hiring and firing mandate.

It is good for Trump that he is ignorant and not smart. He is not in violation of the code because the tax exempt status does not exist.

Much ado about nothing and snowflakes are melting.