The short answer is that it goes to New Jersey. But what happens in New Jersey is surprisingly interesting. Business Insider: "You don't smell garbage. You smell money"
New York City is one of the most wasteful cities in the world. But none of its trash is actually processed in NYC. It's sent to waste-to-energy facilities and landfills as far away as Ohio and South Carolina. It takes a vast network of sanitation workers, trucks, trains, cranes, and barges — and $429 million a year — to get it there.
With climate change looming this is a doomed business, in the long run, and it'll literally be a fight to the death.