It's proper to rinse out one's mouth in the morning so it's clean in order to pray and praise Hashem [1]
If one doesn't have water or the water isn't clean, this rinsing isn't necessary and should pray nonetheless.[2]
On a fast day, one may not rinse out one's mouth with water.[3]
References
↑ S"A 4:17 writes that some have the practice of cleaning out one's mouth in the morning. Kaf HaChaim 4:59 explains that this is done so that one can have a clean mouth for mentioning Hashem's name (in prayer).