You can transfer any Pokémon from Virtual Console games via Poké Bank, as long as its not hacked.
> "With the exception of some glitch Pokémon (they need a certain OT number)." - thecranpper
I don't know what you mean by "Can I move legendaries caught in RBY to SM in Poké Transporter?", but if you are saying, "Can I transfer RBY Pokémon to SM without Poké Bank?", then, no. Pokémon Bank is the only way to transfer Pokémon from Red, Blue or Green.