What is a demat account how it works

Could you explain what a Demat account is and how it works?,