With an open circuit (infinite resistance load), the voltage is a finite number but current is zero, so power is 0.
With a short circuit (zero resistance load), voltage is 0 and current is some finite number, so again power is 0.
With loads in between short circuit and open circuit (i.e. some finite nonzero resistance), both voltage and current are nonzero, so nonzero power is produced.
One or more of those load points will result in a maximum in the power production curve. With real PV cells and real light, one point is the maximum at any given time.