The DNA of the child is irrelevant if the mother was married at the time of the child.
For the purposes of nationality law, the father of a child is the husband or male civil partner of the mother of the child.
Section 50 (Interpretation) of the British Nationality Act 1981 wrote:(9)For the purposes of this Act a child’s mother is the woman who gives birth to the child.
(9A)For the purposes of this Act a child’s father is—
(a)
the husband or male civil partner, at the time of the child’s birth, of the woman who gives birth to the child, or
(b)where a person is treated as the father of the child under section 28 of the Human Fertilisation and Embryology Act 1990 or section 35 or 36 of the Human Fertilisation and Embryology Act 2008, that person, or
(ba)where a person is treated as a parent of the child under section 42 or 43 of the Human Fertilisation and Embryology Act 2008, that person, or
(c)where none of paragraphs (a) to (ba) applies, a person who satisfies prescribed requirements as to proof of paternity.
So, if at the time of the birth of the child, the mother was married to a British citizen husband, he is the father of the child for nationality law and the child acquired British citizenship automatically, regardless of whether he is the biological father of the child or not.
I am not a lawyer or immigration advisor. My statements/comments do not constitute legal advice. E&OE. Please do not PM me for advice.