The key here is that when you create a subprocess that the PID you get back is for the shell of the subprocess. So, what you want to do is to use pkill -P
to kill all the children of the child shell:
(sh child1.sh) &
child=$!
sh child2.sh
pkill -P "$child"