In English "which" is an inquiry for a limited set of choices, while "what" is used when the choices are not limited. If I have two cards-- one red, one green-- and I'm giving you a color blindness test. I would display one card and ask WHICH color is this? If I was in a paint store and I wanted the clerk to match the color of my walls, I could show him or her a card and ask "WHAT color is this?"
Unfortunately, there is no way to identify if a word is masculine or feminine just by looking at it. You just get the hang of it as you become more familiar with the word through exposure to the language.
That said, you can keep certain thumb rules in mind - words ending in ा are generally masculine, words ending in ी are generally feminine, collective nouns are often masculine, abstract nouns are often feminine, words denoting strength and power are generally masculine, those denoting beauty and grace are generally feminine etc.
However, gender is informed as much by etymology and historical usage as by these factors so these thumb rules are not foolproof. For example, both चिड़िया and पक्षी mean 'bird' but चिड़िया is feminine and पक्षी is masculine though their endings lead us to believe otherwise.