Put like that, it is easy to see how a solution to the producer-consumer problem could be used to implement pipes.
In UNIX, pipes are accessed just like files, using the same system calls to write data to a pipe and read data from a pipe as those for reading and writing files. In UNIX, a process which creates a pipe receives two identifiers, one for the reading end, one for the writing end. In a typical case, the creating process would then fork off two child processes, passing to one end of the pipe to one child, and the other end of the pipe to the other child. The two child processes could then communicate.
Pipes may also be generalised to work between machines, with each end of the pipe on a different machine. In this context, it is usually called a connection; the ends of the pipe are called sockets.