To adopt a child, you are going to need a Manor House. You may reuse one from the Architect and Master Architect achievements.
If you don't have a house handy:
Press ~ to open Console.
tgm
Player.AddItem f 999999999999
setstage BYOHhousepale 100
Player.AddItem 03003043 999
Player.AddItem 0300306C 999
Player.AddItem 03005A69 999
Player.AddItem 0300300E 999
Player.AddItem 03003011 999
Player.AddItem 03003035 999
Player.AddItem 03003012 999
Player.AddItem 0300300F 999
coc BYOHHouse3Exterior
Go up to the Drafting Table/Workbench. Build a Small House, upgrade with Main Hall and upgrade one of the wings to a Bedroom.
Press ~ to open Console.
Player.AddItem 000800E4 999
Player.AddItem 03005A68 999
Go to all of the Workbenches and build as much Furniture you can. Requirements are going to be at least one storage and one bed.
Press ~ to open Console.
player.moveto 03004031
Ask Sofie about her parents, then ask to adopt her.