According to the modern cosmological paradigm galaxies and galaxy systems form from tiny density perturbations generated during the very early phase of the evolution of the Universe. Using numerical simulations we study the evolution of phases of density perturbations of different scales to understand the formation and evolution of the cosmic web. We apply the wavelet analysis to follow the evolution of high-density regions (clusters and superclusters) of the cosmic web. We show that the positions of maxima and minima of density waves (their spatial phases) almost do not change during the evolution of the structure. Positions of extrema of density perturbations are the more stable, the larger is the wavelength of perturbations. Combining observational and simulation data we conclude that the skeleton of the cosmic web was present already in an early stage of structure evolution.