Believe it or not, in such a sentence the word 'it' actually has no meaning! The reason has do with the rules of the English language, where the verb 'to be' (I am, he is, she is, it is,...) requires a pronoun (I,he,she, it,...) before the verb is used in what's called an affirmative statement.
Having 'it' available is helpful, because when the pronoun 'it' and the verb 'is' change places, instead of a statement, we produce a question, i.e.,'Is it raining?'.
If we simply said 'Is raining', it could be an affirmative statement, or it could be a question. The inclusion of the meaningless word 'it', combined with the word order, helps clarify things..