the way I see it, Owner/Group www-data / www-data does not have permission to upload anything to wordpress install.
if I am trying to upload stuff using sftp it works but uploaded files in that case have root as owner and I do not feel comfortable uploading files using root user.