Banks these days often don’t hold on to those mortgages though. They can repackage them as securities like MBS and sell them to entities like pension funds. This type of thing is exactly how the GFC started
>>opport+(OP)
Except that the losses are rarely passed on to investors. The issuer (the bank) typically retains first loss (that changed after the 2008 crisis). So it's typically more a tool to get cheap funding than selling mortgages.