Comparing GDP means nothing. Having larger GDP doesn't mean the country is stronger, it is just a number.
Also in this case, you are comparing not the GDP (actually produced goods and services) but a "market cap" which is a virtual number calculated by price of one share multiplied by share count. Yandex shares, I assume, cannot be traded internationally so the number means nothing. Yandex has a public report where one can find out their revenue.