I heard this term many times when I came across some protocol implementations, but could not imagine how 'protocol' relates to 'stack'? Is the stack used here literally a Stack data structure? If so why do we require stacks of protocols at client and server for communication.
"Protocol stack" refers to the specific implementation used. So for example the tcp framework is usually referred to as the "tcp stack". Here stack is used as a term indicating the various "pieces" of the framework.
In this sense, "stack" is unrelated to the stack data structure - it merely refers to how each protocol is built upon those below it.
TCP is built on IP.
IP is built on Ethernet.
Ethernet is built on voltage levels and timings.
So a TCP Stack is the stack of stuff you need to use TCP.
Its a reference to the layering approach to networking. Remember the OSI Reference Model? TCP/IP Model? Basically you break down the network into layers and each layer tackles the problem of networking at a different level of abstraction from the hardware to the application.
Each layer has its own set of protocols and each higher layer uses the lower layer to carry out its job. Like how TCP (transport Layer) uses IP (Network Layer) to send its Frames. When you take all the protocols used in a network to move bits, you "stack" them one on top of the other. The application only sees the protocol at the top of the stack.