Creating stamina or endurance

I have reviewed the responses to this subject in the community and my question comes from a new swimming wanting to know what I need to do to improve my stamina/endurance.  I have been swimming about 3 years and I am up to a mile four times a week.  I would like any suggestion or confirmation that I just need keep working on my technique and my hours of swimming will help me improve my stamina/endurance.  Thank you.