[Abu 'Eisa said:] There is something on this topic from 'Ali. This Hadith is Hasan Gharib.
This is acted upon according to the people of knowledge among the Companions of the Prophet (ﷺ) and others. They dislike separating the captives, the mother and her child, the son and the father, and brothers.
In-book : Book 21, Hadith 27
English translation : Vol. 3, Book 19, Hadith 1566