I don’t see how this is a “scam”, really.
The purposes of these ratings is for people interested in buying debt to have some way of gauging the default risk of the debt issuer. It’s a credit quality rating, a whole different ball game than, say, Morgan Stanley’s analysts giving such-and-such company’s stock a “Strong Buy” versus “Neutral” or “Sell” rating.
When a company issues debt it is asking people to lend it money in return for interest (that’s what a bond is). The first go round, they have “no credit history”.
In a similar situation, if you personally are a first time borrower with no credit history, your options (other than doing without the loan) are basically to find a bank to issue you a loan at likely very high interest rates, if you can even find one willing to do so, or to pay a fee to get a credit evaluation report that the bank will accept.
What Moody’s, S&P, Fitch, etc. do is the same thing, issue a credit evaluation report, but here the company is not seeking a loan from any specific bank but from the market at large. Hence the need for it to be publically available.
The reason the company being rated is the one paying for the evaluation is because without such a rating, the market for their debt is much, much smaller. Most institutional purchasers of debt (mutual funds, pension plans and whatnot) will only buy bonds rated by specific agencies, usually at a minimum credit quality (which is why getting downgraded below BBB is a big deal).