Beowulf is set in Scandinavia in the pre-medieval period. Beowulf is from Geatland, which is actually in the south of modern-day Sweden—Anglo-Saxon "geatas" means Swedes. Interestingly, the word is cognate with Old Norse 'gautar' and is the antecedent of the word "Goths."
Beowulf and his Geats are seen traversing the "whale road" towards Hrothgar's kingdom in the early part of the poem. Hrothgar is the king of the Scyldings, or Danes. He is referred to as "Deniga frean," or the lord of the Danes. We can assume, then, that Beowulf has sailed across the strait which separates Sweden from Denmark in order to help Hrothgar deal with the problems he has been having with Grendel. These problems were so significant that they were heard of even across the sea. It's now believed that the seat of Danish royalty at this time was on the Danish island of Sjaelland, so this may have been Beowulf's destination.
Later in the poem, Beowulf returns with his people to his own kingdom in southern Sweden.