It's possible to live in a caravan or mobile home if you are a member of the European Union. Non-EU citizens have very few chances to get a residence permit for living in Germany. Of course, you can try to apply for a tourist visa and later ask for a residence permit. But this isn't easy, I don't know how it works in your country, but here in Germany, many people were rejected when they applied for a residence permit after being on a tourist visa before.