Hotspots in electronic devices can cause overheating and reduce performance. Enhancing the thermal spreading ability is critical for reducing device temperature to improve the reliability. However, as devices shrink, phonon ballistic effects can increase thermal resistance, making conventional optimization methods less effective. This paper presents a topology optimization method that combines the phonon Boltzmann transport equation with solid isotropic material with penalization method to optimize high thermal conductivity (HTC) material distributions for thermal spreading problems. Results show that the contraction-expansion structure can effectively reduce thermal resistance. Optimal distributions differ from that based on Fourier's heat conduction law, and only the trunk structure appears in optimized layouts due to the size effect. Additionally, HTC material with longer mean free paths tends to be filled around the heat source with a gap in a ballistic-diffusive regime. This work deepens understanding of thermal spreading and aids in thermal optimization of microelectronic chips.