The short answer to your question is that humans have a more developed frontal lobe compared to most other animals. It gives us the ability to perform what are called executive functions, such as organizing and planning long term.
The longer answer is based on one of the running theories within evolutionary medicine, which is as follows: Around the time that human ancestors began to evolutionarily separate from other primates, there is believed to be a period of extensive drought in that region of Africa. Many of these animals were forces out of trees and into plains/savannas which favored more bipedal (walking on 2 feet instead of 4 limbs) animals. The combination of this bipedal movement plus the decrease in plant-based food options, pushed early human ancestors into hunting and increased meat consumption. The meat, being higher in fat and protein than plant-based foods, was more calorically dense. The theory is this excess of calories is what allowed for marked increase in brain size, with the largest growth seen in the frontal lobe. As the brain was growing, it developed more regions for executive function as well as communication. This combination of planning plus communication allowed for the development of societies and even more effective hunting and gathering, providing further evolutionary benefit and development of the brain, which is unique from other animals.
Hope this helps!