It is expected behaviour if your mental model is accurate enough.
My mental model is that a directory is just a special file that links to other files.
Adding or deleting a file to a directory is just a case of writing to the "special file" to add or remove links to other files.