On Baer and quasi-Baer rings