Effects of the nanopits diameter observed at the surface of AlGaN on carrier dynamics are systematically investigated. The diameter variation of nanopits is achieved through the thermal annealing of a set of AlGaN/GaN heterostructures at different temperatures. The samples were characterized using the scanning electron microscope, energy-dispersive X-ray, high-resolution X-ray diffraction, photoluminescence (PL), and time-resolved PL spectroscopies. SEM images have revealed an increase in the nanopits diameter with increasing annealing temperature. Simultaneously, we observed a linear development in the yellow luminescence intensity, accompanied by a deterioration in the PL decay times due to an increase in the density of point-defect complexes that act as nonradiative recombination centers. We also performed temperature-dependent PL measurements to study the impact of nanopits diameter on electron-phonon scattering processes. Both electron-acoustic- and electron-longitudinal optical phonon interactions enhance with increasing nanopits diameter.