Actually there's a few ways to say "if", i.e. 如果,要是,假使jiǎshì,假如jiǎrúand 若是 ruòshì, they can all be used to express "if". "if" in Mandarin isn't only limited to one particular usage, you can use it in the following ways:
1) expressing a fact: 要是你水烧到摄氏一百度就会沸腾, if you heat the water to 100 degrees celcius [then] it will boil.
2) talking about a future result: 假如你认真学外语就会进步- if you study foreign language hard, it will improve.
3)an imagined situation: 假使我很有钱,我就带她去很多地方- If I were rich,I would take her to so many places.
4)if something didn't happen: 如果你没迟到,我就不会那么生气 (if you weren't late, I wouldn't of been so mad.
"ruguo" is more common than all of them. In a learning Chinese book you might only see "ruguo" and you would hear "ruguo" in daily speech. They are all correct to say, and you can use them interchangeably. However, i'd like to note that 要是 can also be used negatively if you place 不 in the middle, i.e. 要是 means "if" 要不是 means "If not.." such as 要不是你,我就不会来- If it wasn't for you, I wouldn't come. Whereas "ruguo" and the others cannot be used in that way.