Each task exclusively owns its mailboxes, so you can guarantee that a message meant for one task is not accidentally received by another. The mailbox is a variant of a simple FIFO, where the task reads the oldest message first. Unlike normal FIFOs, the operating system can reorder the mailbox's contents when high priority messages come in. It's just not enough to send messages. Sometimes a task might need to wait until the message has been accepted by the receiving task before proceeding.
Some kernels use semaphores to synchronize activities.
As you might imagine, the mailboxes, semaphores and queues can eat up a lot of space. Further, each task uses its own share of stack room as well. Most vendors address this by offering some sort of system generation routine. I wrote a system that controls a train moving around a track. Magnetic sensors in the track detected the train passing overhead and send radio messages to a receiver inside the train, stopping and stopping it at each sensor.