Separate the new subpage logic from os_pages_node_submit()

Previously, the logic of adding a subpage to a page node was located
inside the hook os_pages_node_submit(). Hoever, this logic wouldn't
happen on a programmatically created node because it's only triggered
when a node form is submitted.

Now, the new function os_pages_make_subpage() takes the required
arguments and updates the parent and child nodes.
Merge pull request #3553 from openscholar/3307-subpage_api

Separate the new subpage logic from os_pages_node_submit() #3307