Finland had been part of the Russian empire until the Revolution in 1917. (Russia had won it earlier in a war with Sweden). In the general chaos of the revolution and ww1, Finland took the opportunity to declare independence.
Then for whatever reason, the USSR (Stalin, I imagine) decided to try to "take Finland back". Finland saw this coming, and got into a defence pact with Nazi Germany. The USSR saw that as all the more reason why they needed to take Finland back. The USSR was not properly prepared and underestimated Finland. Finland did quite well in that war, and got a bit greedy and tried to expand their own territory into Russia . Because of that, they ended up losing a region called Karelia to Russia. Finland realised they had been quite lucky and stayed very neutral from then on, and had no further problems with the USSR. I think the relationship between Finland and Russia is pretty good at the moment.