For an overview, see the Wikipedia article on the Unrelated Business Income Tax. The specific applicability to churches is set out in IRS Publication 1828 (see the discussion beginning on page 19).
As for diplomatic immunity, here again the law doesn't distinguish between the religious and the secular. Diplomats, whether ordained clergy or not, have immunity from criminal prosecution for even the most heinous crimes. So do our diplomats abroad. Changing that rule would require a major upending of international law.
The specific case of a Vatican diplomat raises a unique issue -- whether we should have such diplomatic relations at all. It has been argued in the past that sending an ambassador to and receiving an ambassador from a religious institution is unconstitutional (in fact, I think JFK took this view). On the other hand, Vatican City is recognized as a sovereign and independent nation. That it's religiously run and that it's very, very small don't deprive it of its sovereign status. On the other other hand, in the case of Monaco we do formally accredit an ambassador but it's the same person accredited as Ambassador to France, because there's no need for a separate embassy in Monaco. By that logic we don't need an ambassador to the Vatican because our embassy to Italy is right there to handle anything that comes up. On the other other other hand, your post wasn't about our ambassador there but about their ambassador here, and Monaco (another very tiny country) does have an accredited Ambassador to the United States. If she were to commit child abuse or murder or whatever, she'd be entitled to diplomatic immunity, so why should a different tiny country elsewhere in Europe be treated differently?
Having gotten to the "other other other hand" level concerning diplomatic immunity, I'm going to take a complete pass on the priest-penitent privilege in the law of evidence.