What is Deed in Lieu of Foreclosure?

A deed of lieu of forclosure is when you transfer the deed of your home to the mortage company that has your loan. This will avoid forclosure. But both parties must agree on this.