The Maximum Modulus Principal states: let $f$ be a function holomorphic on some connected open subset $D$ of the complex plane $\mathbb{C}$ and taking complex values. If $z_{0}$ is a point in $D$ such that $|f(z_{0})|\geq |f(z)|$ for all $z$ in a neighborhood of $z_{0}$, then the function $f$ is constant on $D$.
The notes further state that: “alternatively, the maximum modulus principle can be viewed as a special case of the open mapping theorem, which states that a nonconstant holomorphic function maps open sets to open sets. If $|f|$ attains a local maximum at $z$, then the image of a sufficiently small open neighborhood of $z$ cannot be open. Therefore, $f$ is constant.
Can some explain why intuitively, if $|f|$ attains a local maximum at $z$, then the image of a sufficiently small open neighborhood of $z$ cannot be open?