the statistics memory of the fixed menu is lower than that of the top

I created a container in which I created about 10 processes. I want to analyze how much memory they consume. To achieve this, I ran top inside the container, and docker stats on the outside.

In top, I see 10 processes, each taking 50 MB of resident Memory. So I would wait docker stats to display at least 500 MB of memory used by the container, but only 140 MB.

Where does this gap come from? What is the actual memory consumption?

htop output:
htop output

output of docker statistics:
exit statistics docker