Fixed deprecated twig calls in fields.html.twig

Replaced form.hasParent with a check on form.parent and hasChilden
with form.count