How to have a forward slash in a file name?

Is it possible to name or rename a file so that it has /s in its name [...]?

No, it's not, for obvious reasons.

E.g. consider you have a directory containing:

  • a directory named "foo" containing a file named "bar"
  • a file named "foo/bar"
/path/to/foo/bar # file named "bar" in the directory named "foo"
/path/to/foo/bar # file named "foo/bar"

Referencing either of the two would be ambiguous.

If you're curious as to where the limitation is imposed, that's at the kernel level, in order to comply with the filesystem's specifications.

In general, any character can be used in a filename aside from / (unicode 002f) and \0 (unicode 0000), and filenames such as . and .. are disallowed as well.