My gut reaction is, yes, it is in theory possible, but such orders are made
for the benefit of the child. Nevertheless, the mother will often benefit
indirectly from such an arrangement.
If you were married, then
in a situation like this it is unlikely that you would lose all your
interest in the house. The most likely order would be the so-called Mesher
order, which would give her and the child the right to remain there until
the child was 18 ( more or less ).
But as you are
not married, then it is
possible the Court could make a Mesher order or even order a tenancy until
the child attains majority. I very much doubt if you would lose all your
interest in the house.
Cases like this, unfortunately, as rare
and there is not much experience of what the Courts do. There is no point
in giving her the right to live in your house if she cannot afford to do
so.
But where there are children involved the Courts are quite
prepared to over-ride strict property rights.
LMM