The photocatalytic water splitting into $H_2$ and $O_2$ mimicking a Z-scheme mechanism