(I would think you'd have to have three heads in order for a school to decline your candidacy and save $25-30k a year for three years, but don't know
It can actually cost $80-100K to fund a residency position. In addition to salary, you have benefits, professional liability insurance, travel, office space and supplies and so on.
That said, any program that takes accepts a questionable candidate just because they're paid for is making a huge mistake. Don't even consider the money -- spending 3 years training someone is a huge investment in time and effort on the part of attendings. And residents have a lot of responisbility -- a lousy resident can **** up an awful lot of stuff in 3 years.
A bad resident is worse than no resident.