The diode to the right is hard to avoid in chip construction of MOSfet circuits where the substrate is grounded :
Presentation on theme: "Metal Oxide Semiconductor Field Effect Transistor (MOSFET)" PPT Slides, Dr. M A ISLAM IIUC
The upper diode to Vcc is not part of the MOSfet structure - it is added by the chip designer. It does limit the possible applications of this open-drain output, since a load above Vcc would be limited when this diode forward-biases.
However, the upper diode does help protect the drain from over-voltage (above Vcc). It may be a weak diode only meant for occasional events, like static discharge.
Sometimes, a chip designer would not use that circuit. For example, a chip meant to be powered by Vcc=3.3V might be advertised to have "5V-tolerant I/O". This diode would not be present as shown.