High-energy photons may oscillate with axion-like particles (ALPs) when they propagate through the Milky Way's magnetic field, resulting in an alteration in the observed photon energy spectrum. Ultra-high energy gamma-ray spectra, measured by the Large High Altitude Air Shower Observatory (LHAASO) up to , provide a promising opportunity to investigate the ALP-photon oscillation effect. In this study, we utilize the gamma-ray spectra of four Galactic sources measured by the LHAASO, that is, the Crab Nebula, LHAASO J2226+6057, LHAASO J1908+0621, and LHAASO J1825-1326, to explore this effect. We employ the CLs method to set constraints on the ALP parameters. Our analysis of the observations of the four sources reveals that the ALP-photon coupling is constrained to be smaller than for an ALP mass of at 95% C.L. Combining the observations of the Crab Nebula from the LHAASO and other experiments, we find that the ALP-photon coupling may be set to approximately for an ALP mass of , which is similar to the CAST constraint.