This issue occurs because vSAN does not support the storage of user files in the root of the directory structure. With vSAN, file operations can only take place within namespace objects. Therefore, folders are the only objects permitted within the OSFS (object store file system, the root of a vSAN datastore). This is expected behavior.
To upload files to vSAN, you must first create a subdirectory for the files.