On relationship of atomic structure, nano-sized inhomogeneities and second-order optical non-linearity of K2O-TiO2-P2O5 glasses