There are no restrictions in the Russian legislation on marriage for foreign and Russian citizens.
Meanwhile, Russian law recognizes a monogamous marriages only. Thus, it is required to provide a proof that foreign citizen are not married, if they are to marry in Russia. Typically, it can be a letter from the relevant embassy or consulate in Russia.
Theoretically, a foreign national can marry Russian on the basis of any type of visa. But you should be ready that Russian formalities usualy take at least one month.
So, in this case Visalink reccommends you enter Russia with a long-term visa.