Allied bombers completely leveled more than a quarter of all buildings in the capital city. There was no running water. All bridges were destroyed and there were really no railroads operable. What did civilians eat and drink? And how did they get these necessities?
I would highly recommend reading the book "Berlin at War" by Roger Moorhouse. This book describes what the city, and its everyday citizens went through during the entirety of the war.
What happened to the male population of the city? Basically all the men, old and young, were conscripted in some form to defend the city. The old men and teenage boys (as young as 12) were conscripted in to the Volkssturm (translation: People's Storm) home guard type militia, or in the Wehrmacht (Military), and were given a random assortment of weapons (usually antiquated or captured), and relied heavily on the use of the Panzerfaust (Translation: Tank Fist) Anti-Tank RPG. Oftentimes boys would form bicycle platoons, and ride their bikes armed with Panzerfausts and try to blow up tanks - and usually suffering heavy casualties in the process.
The military aged men, even ones who were lightly wounded (there was a unit comprised of deaf and blind soldiers, who were to rely on one another in their defense) were formed in to Volksgrenadier units formed from decimated Heer (Army) units. The city was also defended heavily by Luftwaffe (Air Force) personnel - namely operating Anti-Aircraft Cannons, and or formed in to Fallschirmjäger (Paratrooper) infantry units. These Luftwaffe units were mostly comprised of former clerks, cooks, logistics personnel, mechanics, and planeless pilots; and were not in fact elite paratroopers, but rather the bottom of the military barrel being scraped clean. Even some foreign Waffen SS units, such as the Charlemagne (French) volunteers fought to defend the Nazi Capital. In the case of this volunteers many joined the Waffen SS and Nazi cause for various reasons (opportunism, hatred of Communism, and or antisemitism etc...), but now realized their proverbial goose was cooked. These foreign volunteers were not welcome home in their newly liberated or neutral countries, and because they were part of the SS they faced lengthy imprisonment (if not out right being summarily executed) if captured by the Soviets, so now could only do one thing - fight bitterly and to the death. They would go down in flames along with their Fuhrer and ideology. However, most of these regular military units (comprised of fighting aged men) were remnants and shells of their former selves, and were no where near as strong as what their types of formations called for on paper / earlier in the war.
Then you had the the SS and Nazi Party functionaries and plutocrats who either stayed in the city to fight to the death (very few actually believed that Hitler could pull something out of thin air to save them) and put on a brave face. But many tried fleeing the city for the Northern or Southern parts of Germany. Including Hitler's soon to be brother-in-law SS Gruppenführer Hermann Fegelein (Hitler's mistress and later short-lived wife, Eva Braun's, sister's husband) was among those former diehards who realized their goose was cooked, and tried escaping. However, like many other military, SS, and civilian personnel who tried fleeing Berlin, Fegelein was captured and sentenced in a brief military tribunal, and was executed the day after his arrest. Many lower ranking soldiers and party members who were caught trying to escape faced a very brief flying court (basically SS execution squads with a Nazi judge driving around in a kubelwagen [German equivalent to a US Jeep] going from sector to sector to find traitors, cowards, deserters etc... ), and were either executed by an SS firing squad, or were hung. Their bodies being strung up from a tree or lamp post, with notes around their necks denoting their cowardly acts, and usually with warnings to other would-be escapees.
What happened to the female population, the elderly and younger children? They tried to survive. They eked out a meager existence, and became 20th century Troglodytes. They lived in the rubble and debris, and were basement dwellers, or hid in churches or air raid shelters, or the U-Bahn (Metro subway) underground stations. Most families chose to move to their basements by the Spring of 1945. Constant shelling and bombing made it unsafe and exceedingly dangerous to live a normal existence above ground.
How did they get food and water? Women and children would queue up for hours at any grocery store that still had food. They would line up for Nazi sponsored food pantries, where food was handed out - sparingly. They saved up their ration food stamps, and used those when they could, or bartered on the black market for simple foodstuffs. Before the Soviets had tightened the noose around Berlin, pushing in from all sides, many Berliner women and children would travel to the suburbs and countryside to try and search for anything edible - but usually only were able to find a meager potato or two, and dandelions and other flowers, roots, and weeds (that was usually thrown in to a pot of water and cooked as an ersatz soup or tea). After a certain point traveling outside of the city to scavenge for food was impossible (although the Military did try to break out towards the West at one point, with many refugees following closely behind - but this was unsuccessful). Essentially they civilian population waited in long lines for bread (which oftentimes was infused with saw dust and other things not normally found in bread, in order to give it some substance), meat was almost impossible to find for your average civilian - unless you came about it via other means (i.e. eating rats, cats etc... and even at one point at the height of the Battle of Berlin, many a Berliner dined on some exotic and unusual animals that had escaped the Berlin Zoo). Now unlike the much lengthier siege of Leningrad, there is very little to no reports of cannibalism (on the already dead or the living) accruing by the civilian populous in Berlin (or any other major German city embroiled in battle). Regardless, the civilian population of Berlin suffered immensely, during the countless bombings of the city, and then the later battle. The best foodstuffs and other luxury items were horded and saved for the Nazi Party functionaries and top military brass, with some of it trickling down to lower ranks. Civilians having a full belly was the least of the Nazis concerns by April 1945.
Now to address another part, how did the Berliner citizen get water? To get water they would bring buckets and canteens and find a water-main that was broken, but still flowing, or find a well. Or they would fetch water from the Spree River - but of course for obvious reasons this was risky. Basically the chores of finding food and water and try to clean up and or fortify their destroyed homes, preoccupied most of the women and their children during the Battle of Berlin and the bombings beforehand.
Of course many civilians were both fleeing to Berlin (from rural areas in Eastern Germany) and fleeing from Berlin (because of the bombing and impending siege and battles) - all to escape the Red Army's steamroll over Germany. So this mass influx and outflow of refugees also heavily burdened Berlin and officials. The new refugees sought shelter in the city because they honestly thought Hitler would defend the city, and defend them, and pull some sort of miracle out of his ass to turn the tide against the Soviet horde. They came from East Prussia, Pomerania, Silesia and other areas of Eastern Germany. They had fled the Soviet advance. They heard stories of the atrocities committed by the Soviets (some even escaped such atrocities), such as the Nemmersdorf Massacre (which was of course exploited for propaganda purposes by the Nazi party). Being pushed onwards towards Berlin out of fear and terror.
The ones fleeing the city westward and northward were trying to reach the Western Allied lines (or the not yet occupied northern parts of Germany), because they realized that the city was defended by teenage boys and middle-aged and elderly men, and foreign volunteer diehards, and a few normal military units. They knew the city would fall. They had been bombed and bloodied for years, and this only intensified as Soviet artillery and Katyusha (Truck mounted multiple rocket launcher) rockets started to rain down on the city in addition to RAF and USAAF bombs of various kinds (including incendiary). However, the vast majority of civilians left alive in the city were trapped. The Red Noose had tightened around Hitler's Nazi Capital's throat, and was being tightened.
So the TL:DR the regular German and Foreign civilians left in Berlin scavenged for food and for water, and waited in long lines for handouts from Nazi functionaries. Otherwise they starved and were dehydrated. Sadly during the battle and for weeks after, Berlin saw one of the worst tragedies in history, with essentially the vast majority of the female population (aged 11 to 80) being raped, and gangraped by pent up Soviet Soldiers seeking vengeance. However, after some law and order was brought back to the city, by the Soviets, the Soviet authorities helped start the process of rebuilding and reforming the city - including helping get water and food to the city.
Edit: Included a little more info. Also here are some resources to check out for further reading on the subject, and that also helped me write the above.
Edit 2: Including a little more information about the lengths the civilian population had to go through in order to get food and water.
"Berlin at War" by Roger Moorehouse
"Endgame, 1945: The Missing Final Chapter of World War II" by David Stafford
"Last Battle: The Classic History of the Battle for Berlin" by Cornelius Ryan
"Savage Continent: Europe in the Aftermath of World War II" by Keith Lowe
"The Fall of Berlin 1945" by Antony Beevor