code: public static boolean newDirectory(Path dir, FileAttribute<?>... attrs) throws IOException
  	{
  		Path directory = Files.createDirectory(dir, attrs);
  		return Files.exists(directory);
  	}
docs: Creates a new directory from the given {@link Path} object and the optional
  {@link FileAttribute}.<br>
  <br>
  Note: this method decorates the {@link Files#createDirectory(Path, FileAttribute...)} and
  returns if the directory is created or not.
  
  @param dir
  the dir the directory to create
  @param attrs
  an optional list of file attributes to set atomically when creating the directory
  @return Returns true if the directory was created otherwise false.
  @throws IOException
  Signals that an I/O exception has occurred.
  @see <code>Files#createDirectory(Path, FileAttribute...)</code>