The basket is part of the tool baristas use to collect freshly grounded coffee and attached to the group handle of a coffee machine.
The tool in question is the portafilter.
Espressos will then start trickling out of the basket and into the serving cup.