As long as it doesn't have convenient access to the rail network or an autobahn you can find a plot with a small, old house on it even 2-3 hours drive from Berlin for next to nothing in a village that had 2x today's population in 1990 (and everyone left there today are old people).
EDIT: example via quick googling of the least-densely populated districts in Germany: https://en.wikipedia.org/wiki/Prignitz
It has fewer people living in it today than it had in 1875 (earliest available data) & half as much as it had in its peak in 1950. It is about 2 hours drive from Berlin according to google maps.
Looking at houses for sale in the state of Brandenburg with price limit of €10k gives several results (some of them probably dubious but not all): https://www.immobilienscout24.de/Suche/de/brandenburg/haus-k...
It will not be a comfy home for a family but for the type of stuff discussed above it would do (e.g. a formerly abandoned but still standing/stable house).