We don't know what the materials are like that the make up the robots. We don't even know for sure that they are made from the same materials since the robots vary so wildly that they don't follow any of the rules we have for being a species here on Earth. Thus like cars on Earth perhaps some are more susceptible to a rust than others. I'm also thinking that the weapon wasn't actually a rust weapon but that the side effect of the weapon doing it's job was to make it look like rust. The weapon could have shot some sort of nanites that disassemble at a microscopic level but as they consume, replicate and then fall off they look like rust.