We can describe it like this: Definition of a granny flat: “What defines a granny flat today is legally clearly defined. The crucial point is that it is a self-contained residential unit within a residential building. A separate entrance is not strictly necessary. Sharing a hallway or stairwell is also permitted. However, sharing a kitchen or bathroom is not allowed. Because a granny flat must provide its residents the possibility to run an independent household. Completely independent from the other rooms in the house.” Source: Schwäbisch Hall.
But this is more interesting, and it comes to the point further below: “Regarding room height, the state building codes give very specific requirements about what applies in your federal state. For example, a basement used as living space must meet a minimum room height. 2.30 meters is considered the lower limit, but 2.40 meters or 2.50 meters room height would be better.” “Check what applies in your federal state. If your basement does not meet this basic requirement, it can become a knockout criterion, because the room height cannot be corrected afterward.” Etc. Source: mein Eigenheim
The KfW bank assumes that everything is correct, since they only support granny flats. If you do not legally build a granny flat, you do not need to submit an application.