In November, Russia hosted peace talks about Afghanistan. The conference brought together diplomatic representatives from the Afghan government and the Taliban, which had refused to attend the two previous rounds of these talks in 2017.

And yet this conference, too, ended in failure. The Taliban condemned the Afghan president as illegitimate; the Afghan government accused Russia of boosting the Taliban’s legitimacy on the world stage. Nevertheless the Russian Foreign Ministry described the talks as a historic step, potentially leading toward peace. Why would the Russian government get involved in — and continue with — diplomacy that’s likely to fail?

My research suggests that the answer lies in the Kremlin’s interest in its reputation among its own citizens. The Russian government uses crisis diplomacy to rally Russian public support and influence public opinion along three main lines, as I’ll explain below.

1. The Kremlin is emphasizing that the U.S. has double standards

In February 2007, Russian President Vladimir Putin delivered a scathing anti-Western address at the Munich Security Conference, marking a new foreign policy stance. Since then, Russian officials have regularly argued that U.S. foreign policy is hypocritical — an emphasis that has strongly influenced Russian public opinion.

The Levada Center is an independent polling agency that regularly surveys Russian public opinion. By analyzing its data from the 2003 Iraq War to now, I found that over 70 percent of Russians consistently believe that when the United States promotes democratic values, it’s really just a front for expanding American influence and power worldwide. That’s been true even when the United States and Russia weren’t especially at odds.

And so when the U.S. government claims that the Moscow talks are just legitimizing the Taliban, the Russian government argues that the United States is hypocritically using double standards. For instance, Russian state media outlets have pointed out that the U.S. special representative to Afghanistan, Zalmay Khalilzad, met Taliban officials without Kabul’s consent. Russian media also quotes conciliatory Afghan politicians, including former president Hamid Karzai, who contends that Moscow’s Taliban outreach is similar to U.S. diplomatic overtures.

Why emphasize this double-standards narrative? First, it helps reassure Russians about the fact that Russia invited the Taliban, which the Kremlin designates as a terrorist group, to a multilateral forum. Second, it reinforces the public’s belief that the West is trying to marginalize Russia — and shows Putin as a strong leader willing to stand up to the aggressive United States to preserve Russia’s foreign policy independence.

2. The Kremlin is also trying to position Russia as an indispensable power

Many Russians want their country to be less isolated from the West. A 2016 Levada Center poll revealed that 62 percent of Russians supported increased dialogue with Western powers, and only 24 percent wanted to remain isolated from the West.

But they don’t want that to happen through appeasement. Putin’s strategy is to achieve that goal by becoming an indispensable player in world affairs. And that’s what the Kremlin is doing in the Afghanistan talks: trying to show that Russia has unique diplomatic leverage over the Taliban.

On Nov. 12, the Russian president’s special envoy to Afghanistan, Zamir Kabulov, said that having the Taliban at the Moscow talks could lead to peace talks that would include the United States. And on Dec. 3, the Russian Foreign Ministry announced that Khalilzad would meet with his Russian counterpart, Kabulov, to discuss the Taliban’s preconditions for peace.

It’s unclear whether the United States would withdraw troops from Afghanistan, as President Trump says he has ordered. But the United States is unlikely to lift its long-standing sanctions against the Taliban. Nevertheless, Putin can frame any U.S. consultations of Russia as a major diplomatic victory. The Kremlin may be cultivating an image of indispensability in crisis areas like Afghanistan to increase public confidence in the Russian Foreign Ministry, and distract from the economic frustrations that have eroded Putin’s approval ratings.

3. The Kremlin wants to reassure Russians that it has a strong diplomatic relationship with India

Russia has been building a diplomatic partnership with India over the past decade, bringing public opinion along with it. A 2017 Levada Center poll found that Russians see India as one of Russia’s five most significant international partners. The popularity of Russia’s alliance with India can be explained in part by positive memories of a similarly strong Soviet-era relationship. Further, India fits well into Russia’s vision for a multipolar world order, which allows non-Western powers to challenge the United States on equal terms.

Russia-India ties have frayed lately, however, as Moscow has strengthened its partnership with Pakistan and as the United States has improved its ties with India. And so India’s decision to send an unofficial delegation to the Moscow talks helped counter Russian public concerns that the two countries’ relationship was deteriorating.

That may be why Russia called for India to stay more closely involved in diplomatic summits that seek to end the war in Afghanistan. If Russia can successfully encourage India to engage in dialogue with the Taliban over Afghanistan, Russian public confidence in both the government’s arbitration skills and in Putin’s status as a global statesman will immeasurably increase.

In other words, Russia saw these talks as a success in no small part because they were aimed at a popular domestic audience. Nationalists at home got to see Russia showing its foreign policy independence from the West, indispensability as a great power and close alliance with India.

Samuel Ramani (@samramani2) is a doctoral candidate in international relations at the University of Oxford specializing in post-1991 Russian foreign policy.