Which item goes next?
Picture a stack of plates. You add a plate on top and take the top one first. Software stacks work the same way. An undo feature may use a stack so the most recent action is undone first.
A queue is more like a line at a café: the first item added is normally handled first. A message queue can hold work for another part of a system. Real systems may prioritise some messages or process several at once, so delivery order is not always guaranteed.