Never had high BP before then had 2nd csection, and BP was very high. Was told postpartum hypertension. 3 yrs later, still on BP meds. What caused this?

Not unusual. Often pregnancy induced hypertension is a precursor for persisting hypertension. Continue your meds.
Genetics & lifestyle. Essential hypertension (high blood pressure =hi bp) is very common in the western world due to genetics and our high salt, high fat diets. Also contributing to hi BP is our sedentary lifestyles (80% population is sedentary) and obesity. So with the tendency to get hi BP and pregnancy weight gain both can combine to produce hi BP which can persist. Pregnancy can unmask diabetes, too.