The First Russo-Persian War (1722-23) resulted in large gains for Russia, and alliances with the Georgians and Armenians. These gains were the southern coast of the Caspian Sea. The gains were given back to the Persians in order to get the Persians into an anti-Ottoman alliance. Let's say those gains aren't returned. With those gains in hand, then the Russians have a better base from which to launch further attacks.
With control of the southern coast of the Caspian Sea, the Russians get more involved in the Persians' war for the Peacock Throne. Catherine gets directly involved in the war, and decides to support one of the claimants, placing a Russian puppet on the Peacock Throne.
When Catherine dies, Russian support immediately ends, and the puppet is overthrown. Under Alexander I the Russians take more interest in the Persians, and once again start intervening in Persia. Alexander I's war against the Persians (1818-1823) Once again puts a Russian puppet on the Persian throne. The Russian move is opposed by the British, who support their own candidate, and the Peacock Throne remains contested. Meanwhile, the Russian wring territorial concessions out of their puppet, extending their territory, but fatally weaken him, and the British candidate defeats and executes his Russian rival.
The Russian-British rivalry continues, but with the Russian control of more territory in the Caucus and with control of the entire Caspian Sea litterol, the Russians push into eastern Anatolia, taking control of Armenia by the mid-19th century. With this base, as the Russian rivalry with the British grows the Russians look for a warm water port, they decide that Basra is the perfect place to get one. The Russians go for Basra, and successfully get it from the Ottomans. The result of all this rivalry in Persia is that formal annexation by both the British and Russians is increased. Ultimately the Russians control a lot of territory, and the British end up as the formal protectors of the Shah, with a similar relationship to the Indian princes. The Russians get Basra, but in the process the British end up with control of the Straight of Hormuz, so control of Basra is rather pointless.