"I swim at a pool."
there's exceptions to that, like 角を曲がる、道を歩く、etc. but you're generally right. in the case of the verb 泳ぐ, you technically can use を to indicate which way you're swimming (so it would be grammatically correct here, but the meaning wouldn't make sense, so Duo will mark you wrong)
the particles are usually attached to the noun to the left, in this case で doesn't have anything to do with the verb but more like is what indicates where the action (verb) happens.
The comment above is wrong, you can indeed use any particle with any verb because that's how japanese works, they are just the grammatical bits that identifies who does what.
Now for this particular example you can only use で to mark プール because that's the location in which you swim, is like saying "I swim at the pool", in that case you cannot use に because for japanese people the pool is either a location in which the swimming happens or the means in which your swimming can happen. Using に would mean something like "I swim into the pool" which makes no sense even in english unless you are able to swim in the air, or if there is a pool inside the pool idk.
However like I said before you can indeed use に in other situations, for example you can say「夏にプールで泳ぎます」"I will swim at the pool in summer" but in that case に is marking an specific time on the timeline and you can see the difference it makes with both nouns "summer" and "pool" with their respective particles.
Would it be incorrect to say プールを泳ぎます? As the action of swimming would take place at the pool. Or is プール only meant as "the area including water, lifeguard chairs, and diving boards" and not "the water at the pool?"
Now, could I say プールで水を泳ぎます?
I swim (through / in) the water at the "pool-area."
I think youre right for the most part, but just not in this case. The sentences "I swim in the pool" and "I swim at the pool" are both correct english sentence, but they mean two different things.
The phrase "i swim at the pool" can be better understood by replacing the phrase 'the pool' with something else. For example lets use 'the YMCA'. "I swim at the YMCA" should sound natural. Whereas "I swim in the YMCA" sounds off. That's because when we say "I x at the Y" we are not talking about the physical medium we are swimming inside of, instead we are describing a general location where the action is taking place.
As for the translation, the version with 'at' is the more correct one. The reason being that in this case で is talking about the general location where the action is taking place. But that being said it would be better if both tranlsations were marked as correct
I find out that に is focused on where you are,
and the で is focused on what you do.
Either way you'd be understood. I think by swapping "in" for "at" in that sentence, you're treating the pool more like a location than an object (it's weird to describe a pool as an object but I couldn't really think of a better word to explain the subtle differences in emphasis that "in" and "at" create). You'd most likely only say "I swam at the pool" if you had already left the pool and were recounting the details of your day to someone else, or if you're telling someone your plans for the day you could say, "I'm swimming at the pool today" and you'd be understood as saying "I'm going to go to the pool today and swim there." In certain contexts, you could also use that same sentence to emphasize that you're swimming at the community pool or your neighborhood pool instead of somewhere else with a pool, like the gym.
If, however, you were physically at the pool, then saying something like "I'm going to get in the pool," or "I'm going to swim in the pool now," would be more natural.
From how it was explained to me, で is for actions happening at a location. I. E. 学校(がっこう)で勉強(べんきょう)します, I study at school. Vs. に/へ, which indicates going somewhere, I. E. 学校 (がっこう)に行きます(いきます), I go to school.