Frost's poem "Mending Wall" is a contemplative journey through Frost's thoughts as he ponders what purpose the stone wall between him and his neighbor really serves. Personally, he doesn't really see a need for a wall; they don't have cows that will wander into each other's yards, and it's not like his apples will "get across /And eat the cones under his pines". So, he wonders why, every spring, they go about fixing and mending the old stone wall between their plots of land.
In the poem, there is no mention of the Berlin wall; the lines I think that you might be referring to are these:
"Before I built a wall I'd ask to know /What I was walling in or walling out, /And to whom I was like to give offence"
Here, Frost thinks that before he builds a wall, he'd like to know why. What purpose does it serve? Is it walling something in, like cows, valuable property on his land, or his own hand of friendship? Is it walling out danger, threats, or on the other hand, potential friends or kindness? He worries that putting up a wall on his land might offend someone, because they might get the impression that Frost doesn't like or trust them.
If you DID want to tie this to the Berlin wall, that wall was constructed to maintain control, to separate realms of power, and it was an awful and destructive force to many families and Germans. Here is an example of a wall that does doe what Frost thinks walls might: restricts, offends, and brings us all back to the age of barbarism, where people fought and killed over boundary lines. I hope those thoughts help; good luck!