"DeFi" is more than just giving your crypto to someone you don't know, but there are certainly risks.
One form of defi is providing liquidity. As users swap between the tokens you provide, you collect a share of the fees. No lending/borrowing, but you are giving your tokens to the platform that's providing the service--so you'd need to trust, for example, Uniswap.
Most lending platforms use collateralized borrowing. As a borrower, you you provide 3x what you're borrowing as collateral; if you don't pay it back, the platform actually makes MORE than if you did.
Those are the two most common forms of defi, in my opinion, and neither seem particularly high-risk. But you're right, you are giving your crypto to someone else just like when you give your money to a bank.