The ridges help the pieces of pasta hold onto sauce better.
You will also see the “rigata” spelled with an “e” or an “i” on the end when it is used in combination with a plural word. e.g. penne rigate.
The word “Rigata” comes from the Italian word “rigare”, meaning to score lines or mark lines into something. The past participle of this is “rigato”, which means “lined”, or “ridged.”