Most people, especially people trying to learn how to swim, do not understand how buoyant their body actually is in either salt or fresh water. That is why you see new, inexperienced, apprehensive swimmers and snorkelers thrashing about in the water, furiously kicking and moving hands trying to stay afloat. They don't realize that all that flailing is actually detrimental to staying afloat and it wears them out in short order.
Here is a suggestion that I used when teaching swimming, most recently when I taught my non-swimming wife how to swim and tread water prior to taking her OW cert course. There are many ways to reach the end objective, but this is one that worked for my wife.
First, read up on drown proofing techniques. Then, don a scuba mask or swim goggles and practice those procedures in a pool, close to the side, until you are comfortable and confident that you won't sink if you are not furiously kicking and moving your arms. The mask or goggles will help you see that even if most of your head is in the water, you are not sinking like a stone to bottom of the pool. When you are comfortable and confident, then add a slow and easy cycle of figure 8 movements with your arms and easy scissors kicks with your feet to tread water.
FWIW, my wife not only learned how to swim, she did the 200 meter swim using a combination of breast, side, and back stroke, had no problem with the water tread, and did a great job on her OW course. If she could do it, you can do it.