What's the scam? Why would someone place millions of dollars' worth of liens on homes they have no affiliation with?

There are different kinds of liens. You are talking about a mechanic’s lien. If you win a lawsuit against someone who either can’t or refuses to pay the damages, you can slap a lien on any identifiable property – real estate, personal property, bank accounts, etc. The trick usually is to find something owned by the entity that you sued. When I was a kid I delivered advertiser-type newspapers in my neighborhood for a small company that then went bankrupt and failed to pay me. My father won against them (not in attendance) in small claims court, but there was no way to collect, the entity that was supposed to pay me had dissolved itself.

The description I heard for that entity was ‘legal turnip’. You can’t squeeze blood from one.

Strangely, having inspected jails, breakfast is not a hot mean, and lunch is sandwich and soup or fruit (no choice).

Nothing strange about it, including the fact that the old rhyming phrase* is no longer nit-pickily accurate. Well beside the point, in fact.

*borrowed, I think, from army boot camp, in which it may also no longer be perfectly representative of the fare on offer.

So basically a lein must be either (a) work done on the property or (b) a court order for repayment of a debt.

More than once, when I was cashiering, I would hear a kid say, “Just write a check, so we don’t have to pay for it.” Doesn’t work that way either!

(My brother once had a roommate who didn’t comprehend that checks needed to be backed by actual money in the bank.)

I don’t remember who it was but decades ago when the Discover card was introduced there was a comedian who had a monologue that went something like,

Discover card. Yeah they got that named right. You see, I got one of them and then after a month I Discovered, I’d run up $8,000!

Then they Discovered, I can’t pay for all that stuff.

Then I Discovered, they don’t like that.

So, now they’re trying to Discover where I’ve moved to.