Why is "Tá uisce ar an fhuinneog" also accepted?
Because in Ulster, use of preposition plus singular definite article (otherwise known as the dative) lenites, and the standard has revently changed to accept it.
Please see here: https://www.duolingo.com/comment/5242925 It was partly inspired by your question :)
Why do you put the h and b in the first place
Try the Collins Irish Grammar e-book. It explains it very well.
but its poor in some other areas, e.g. formation of genitives. Really disappointed as I have the Spanish version and it´s excellent...
Prepositions typically eclipse the following noun, and <f> is eclipsed by <bh>. You then pronounce the <bh> in place of the <f>.
Check out the instruction under the "Eclipsis" skill.