How did World War 2 set the stage for the Cold War?
WWII brought up specific challenges to Western democracies. Specifically, how did they reconcile working with the Soviet Union, which was known for its totalitarian and undemocratic policies, in order to bring about the end of totalitarian states such as Germany and Japan? This was done through putting ideological differences aside to combat an even greater menace.
But this did not mean that US (and UK) were ignorant regarding the USSR's ambitions or its belligerence towards weaker powers in its orbit. Nor did this mean that the USSR was willing to accept ideological differences and leave it at that. As WWII progressed and it became clear that Germany and Japan would be defeated, there remained the question of which ideology—democracy or socialism—would hold sway in the future.
In some ways the war ushered in the Cold War because it forced the militarization of all countries. The USSR grew in military might as did the US which also developed nuclear capabilities. The forcefulness of Marxist theory and its stress on the "inevitability" of capitalism's collapse also served as a vehicle for the USSR's fomenting revolution in neighboring countries in Central Asia and Eastern Europe. This rallied a similar response by the US and UK, particularly following the collapse of Germany. The USSR occupied the East, thus expanding the Soviet empire, while the Allied powers occupied the west in an attempt to stop its spread. WWII therefore brought to a head what had been fomenting for years: the clash of political ideologies.