@Tal69: There are no rules for determining the gender of a noun in Spanish. What you quoted are just generalizations to make learning a bit easier, but by no means are rules and even less they are infallible, as you have already seen from Julvenzor's examples.
Also, these two generalizations involve nouns that end with a vowel, but the word "flor" ends with a consonant. And then, even though most nouns ending with "r" are masculine, "flor" is an exception.
Genders must be memorized, but the only way to get them right every time is to practice the language; over time these things come naturally.