pull down to refresh

There are numerous reasons stablecoins are used. A big use case is for lending, for the purpose of earning interest. Another use case is to hold funds as "dry powder" to have tradable funds ready for trading should an opportunity present itself. Traders who perform arbitrage trading and need to move a USD balance from one exchange to another, so a stablecoin can be used to perform that transfer.
And then there's the DeFi use case you describe. A smart contract can act on a stablecoin token same as it would act on any other token for that chain. And a stablecoin can be issued on various blockchains. For example, Tether is on bitcoin (OMNI), Ethererum, Tron, and about a half dozen other blockchains.
And there are different types of stablecoins. There are ones for different currencies ... e.g., Tether has a EURt stablecoin.
Here's the Wikipedia article on stablecoins: