Millimeter-wave (mmWave) and Terahertz (THz) will be used in the sixth-generation (6G) wireless systems, especially for indoor scenarios. This paper presents an indoor three-dimensional (3-D) statistical channel model for mmWave and sub-THz frequencies, which is developed from extensive channel propagation measurements conducted in an office building at 28 GHz and 140 GHz in 2014 and 2019. Over 15,000 power delay profiles (PDPs) were recorded to study channel statistics such as the number of time clusters, cluster delays, and cluster powers. All the parameters required in the channel generation procedure are derived from empirical measurement data for 28 GHz and 140 GHz line-of-sight (LOS) and non-line-of-sight (NLOS) scenarios. The channel model is validated by showing that the simulated root mean square (RMS) delay spread and RMS angular spread yield good agreements with measured values. An indoor channel simulation software is built upon the popular NYUSIM outdoor channel simulator, which can generate realistic channel impulse response, PDP, and power angular spectrum.