Sets the read-only property of the file to true.