If the node contains fewer than the maximum legal number of elements, then there is room for the new element. Insert the new element in the node, keeping the node's elements ordered.
Otherwise the node is full, evenly split it into two nodes so:
A single median is chosen from among the leaf's elements and the new element.
Values less than the median are put in the new left node and values greater than the median are put in the new right node, with the median acting as a separation value.
The separation value is inserted in the node's parent, which may cause it to be split, and so on. If the node has no parent (i.e., the node was the root), create a new root above this node (increasing the height of the tree).