Web services middleware plays the "middleman" role in the overall software architecture. The middleware layer can address things like security or cross-platform communications. It may also allow messaging between different software components. It is like a connective glue for a greater software structure.
Web services middleware works like a client-server architecture where the Web services application is the client and the middleware is the server, that is, it provides services to the client. This is how many engineers and developers think about the process when they add Web services middleware to a particular application.