が (GA) is used to mark the subject in the sentence. は (WA) can be used too when the subject is also the topic of the sentence.
Keitai denwa no denchi ga kirete iru.
The phone battery has run down.
The particle が (GA) is often used with ある (ARU) or いる (IRU) to mark the object of the sentence. ARU is used with inanimate entities (car, food, plants, etc.), and IRU with animate entities (animals, humans).
NOTE: the polite forms for ARU and IRU are ARIMASU and IMASU.
Niwa ni neko ga imasu.
There’s a cat in the garden.
After interrogative pronouns (what, who, etc.) in questions, が (GA) is always used, never は (WA) because if we ask a question about the element related to the question, it means that this element has not been identified yet. It's a new element introduced in the conversation.
Dare ga anata no tomodachi desu ka.
Who is your friend?
The particle が (GA) can be used with verbs or adjectives of desire, capacity, necessity, perception and emotion to mark the object.