DeFi (Decentralized finance) refers to decentralized finance based on blockchain technology and aims to replace the roles…