“1618?. If a fasting person intentionally immerses his entire head in the water, his fast is known to be void, even if the rest of his body remains out of water. But this act does not invalidate the? fast; it is a Makrooh act, and as a measure of precaution, should be avoided.”

http://www.sistani.o…&id=48&pid=2269

I’m not sure what Sayed Sistani means here. First he says it will be known to be void, but then it's described as only being Makrooh. Perhaps you can clarify the actual meaning?? And also finally answer the question on whether it’s allowed to swim while fasting.

He means that it is famous among the Scholars this act voids the fast, but according to him, it does not.
However, it is better to avoid it.