Select wrong batch in pick list

I have a problem here:
As I understand it, when I create the pick list, it should select the batch that were received first according to the existing FIFO settings.

But as shown in the screenshot below:
I have 1600 products in the same batch but in different warehouses. When I create a pick list of 800 items, the software does not follow the batch order (the correct order should be to pick all from batch 1 before moving to batch 2).

Is it a bug? And how can i fix that?

I think it gets the batch based on Warehouse. Are mentioning the Source Warehouse in Sales Order?