Enhancing Stability and Photostability of CsPbI3 by Reducing Its Dimensionality