The VC takes a minority stake in the company (<50%) while management and any other existing owners hold >51% of the equity, thus retaining control. VCs are generally not interested in running the business, they’ll take a small stake and provide advice and access to their network, then cash out at a later stage.
Management can either stay in the business or they get replaced by new management being brought in. The key point is that they surrender their control, so the acquiring party - generally a PE fund - has the ability to get rid of them if they want to (whoever holds control of the company has the right to hire and fire management.)
In practice, even if the acquiring party wants to replace management, they often structure the deal so that management at least stays on for a while to facilitate the transition (for example, they could be paid partially in new shares)