I did as you posted. Posts sort by IDs correctly. I misunderstood at first how it works.
I’ll refine the question:
Is it possible to make posts according to a specific custom order?
And how to do it?
I found this https://wpshowposts.com/support/topic/sort-by-custom-field-value/#post-7803 but I don’t know (I don’t understand) what I can do with it.