The Department of Housing and Urban Development said Wednesday that it would investigate the lending practices of certain mortgage lenders to see if any prospective borrowers had been illegally denied a mortgage because they were pregnant or on short-term disability.