Broadly, yes, that's what most medical doctors are taught, and its mostly true, if you eat predominantly unprocessed foods.
Natural fibre is important, to allow a good gut biome as well. Lots processed foods will shorten most people's lifespan though, IMO.
For sure you can wreck your health...