How does exchanges, such as coinbase handle off-chain transaction? Does coinbase create a channel between each customer and coinbase itself?

If i buy 10 USD of bitcoin from coinbase, where does the 10 USD worth of bitcoin come from? Does coinbase maintain a huge wallet that belongs to itself, and creates a payment channel with each individual customers?
Yes, exchanges tend to have huge cold wallet where they amass and send most of their bitcoins ( you can even follow those addresses by each exchange on the top 100 richest bitcoin addresses )

When a user want to withdraw fund they can use smaller hot wallet to send coins, some exchanges will use payment channel for the transfer but most have not adopted it, or choose not to.

For more detail about how they do that you can check this question How do cryptocurrency exchanges handle users&#39; accounts?