Life doesn’t necessarily need to exist, no. If you look at the other planets in our solar system, they seem to be managing just fine without life! As it so happens, the conditions on Earth were such that it was very easy for life to develop. But your question is quite a philosophical one – if life didn’t exist, would there be any point to the universe? That might suggest that life needs to exist for the universe, in some way, to exist. But we don’t know that for sure, because it’s impossible to imagine what things might be without life.