Honestly if unles we use the Morgenthau plan (which also in the end wouldn't cause it, because Morgenthau Germany's birthrate would boom afterward), we need East Germany to embrace natalistic policies which increase their birth rates, East Gemany already in OTL did have a higher birthrate, but it wasn't much high enough. Through even with natalistic policies it's hard.
So we need Stalin to get that Germany won't unite early on, and GDR need to be strong to be seen as the legitimate Germany. So let's say that he let East Germany keep Weimar's eastern border. This keep 9 million Germans in these territories. Next the Germans expelled from Czechoslovakia and Poland are send to GDR, this give it a extra 4 million people to GDR. Some refugees ended up in GDR, but 12 million ended up in FRG. So if we look at the demography this give FRG a smaller starting population. Let's round it of to 40 millions instead of 51 millions. GDR instead start with mopre refugees ending up in their state, a lower death rate than in OTL. So they have a starting population of 30 millions. This seem much more equal than OTL 51/18 million split.
Next we need to stop GDR bleeding. Ths solution here could be that USSR doesn't make East Berlin part of GDR, but instead make it a "independent" city with limits on East German immigration which limit the outflow to the the west. The East German capital is moved to Strettin or Frankfurt am Oder. This all limit the emigration to FRG. Next East Germany continue the natalistic policies of Nazi Germany and give special right to people who get children (access to bigger housing, bigger cars, shorten the queue for these product, monetary rewards for producing children etc). All this cause the East Germans to have a higher birth rate than West Germany, through West Germany also produce more children, as it also become a success criteria for them. By 1989 both countries have slightly above 50 million people.