When / is part of a regular expression that you want to replace with the s (substitute) sed command, you can use a different character instead of a slash in the command syntax, so you write, for example:
sed 's,/,\\\\,g'
above , used instead of the usual slash to distinguish between two parameters of the s command: a regular expression that describes the replaced part, and a string to be used as a replacement.
The above will replace each slash with two backslashes. A backslash is a special (quoted) character, so it must be quoted, here it quotes on its own that we need 4 backslashes to represent two backslashes.
$ echo /etc/passwd| sed 's,/,\\\\,g' \\etc\\passwd
piokuc
source share