There are lots of things dissolved in our water that give it “flavour”, but the goal of all utilities is to minimize this as much as possible. Some water objectively tastes better than others, and a common segment of local drinking water conferences is a taste test. That said, for normal people usually the water they prefer is what their palette is used to. Someone who grew up drinking groundwater with very high alkalinity and pH will prefer that over surface water that is actually more “pure”. Similarly, if you normally drink water from a private well that you don’t add chlorine to, you likely dislike the taste of “city water”.
The common offenders for bad tasting water are excessive chlorine and some specific organic compounds. Both of these flavours can be removed using a granular activated carbon filter (e.g., a Britta), but you can actually remove the chlorine by just letting your water sit in the fridge for a while.
Water is disinfected with either chlorine, chloramine (ammonia + chlorine), ozone, or UV light. In North America chlorine is almost universal because it provides disinfection residual, which keeps water safe while it is travelling from the treatment plant to the consumer. Fluoride is added solely as a supplement to improve dental health.