This is a fascinating, and I think very hard question. I tried to give an answer once before with the statement:
Research by psychologists has shown that babies, as young as three or four days old, can tell the difference between collections of two and three items. By four and a half months of age they can tell that one plus one is two. Some animals also can estimate small integers and do simple arithmetic. So what is the origin of integers? It seems that, at least the first three positive integers, are with us at birth.
This ability to "see" one, two or three objects seems to be innate in almost all of us. We can look at a collection of one, two or three objects and immediately know how many there are. If you show me twelve objects then I have to use some method of counting to determine that there are twelve and not eleven or thirteen. This ability to immediately know that there are one, two or three objects is called subitizing. Some people claim to be able to subitize up to six or seven objects, but three seems to be innate in almost everyone.
So, what is the origin of the rest of the positive integers? They probably come from the desire to abstract the idea of two collections of objects having the same size. By abstract I mean some concept that is common to all collections of the same size, not just a particular collection of that size.
Let me give you an example. On the first day of classes in the school year the grade three students show up in the auditorium. The teacher wants to know if there are enough desks in her classroom for all the students. She could take the students to the classroom and have them all sit down. If they do, and there are desks left over, then there are more desks than students. If they try to sit down and the desks are full but some students are left standing, then there are more students than desks. A more practical method would be to use integers. She could count the number of desks (she got 28) and count the number of students (she got 30) so she then knows that there are more students than desks (30 is larger than 28).
I hope this helps,