public static Map<String, Object> newDocument(Document parent, String key) {
        requireNonNull(parent);
        requireNonNull(key);

        final List<Map<String, Object>> children = parent.get(key)
            .map(DocumentUtil::castToDocumentList)
            .orElseGet(() -> {
                final List<Map<String, Object>> list = 
                    new CopyOnWriteArrayList<>();
                
                parent.put(key, list);
                return list;
            });

        final Map<String, Object> child = new ConcurrentSkipListMap<>();
        children.add(child);

        return child;
    }
Creates and returns a new raw map on a specified key in the specified
document. This might involve creating a new list if no such existed
already. If children already existed on that key, the new one is simply
added to the end of the list.

@param parent the parent to create it in
@param key the key to create it under
@return the newly creating raw child map
runtime-parent/runtime-config/src/main/java/com/speedment/runtime/config/util/DocumentUtil.java