os.makedirs("path/child", exist_ok=True)
If exist_ok is not specified or is False, and the target path already exists, then FileExistsError is raised.
exist_ok
False
FileExistsError