Immaterial consciousness seems to inhabit a physical body and look out upon a material universe. This is the problem of accounting for inner experience in terms of an outer perspective-- Leibniz' famous "ghost in the machine":
"It must be confessed...that perception and that which depends on it are inexplicable by mechanical causes...And supposing that there were a machine so constructed as to think, feel and have perception, we could think of it as enlarged and yet preserving the same proportions, so that we might enter into it as into a mill. And this granted, we should only find on visiting it, pieces which push one against another, but never anything by which to explain a perception." 
The major philosophical attempts to reconcile these perspectives have been of two broad types, according to whether they are admitted on an equal footing or whether one is reduced to the other or otherwise dismissed as unimportant. Dualism holds that there are simply two kinds of existence in the universe--mental and physical--neither of which is reducible to the other. Monism, by contrast, takes one as primary and attempts to show how the other arises from it. There have been three major brands of monism: materialism (or realism), idealism, and "emergentism" (or neutral monism). The first argues that only the physical world exists. In recent times, this is the approach of stimulus-response psychology, according to which the mind is a reflex machine operating by association. Consciousness is held to be an "epiphenomenon" without causal power.
Idealism takes the opposite stance: only the mental or "phenomenal" world exists. Matter is but an idea, a theory, or construct of the mind to help make sense of the flow of experience. Western idealism has been taken up in modern times by cognitive psychology. Eastern idealism asserts that only the ground of Being is real. Both the inner and outer worlds are illusory--not that they do not exist but that one's unreflective relationship to them is a source of error and suffering to be transcended.
Theories of emergence usually extend materialism. In one version, mind, like life itself, is described as a property of the organization of matter at a certain level of complexity. This modern view relates mind to concepts like order and information.
The universe as a complex system appears to manifest intelligent design. To understand Nature as something like the work of human hands must have been one of the earliest and most natural reflections. But to infer that such intelligent design is literally the result of a non-material Artisan at play in the primordial soup is to duplicate the Mind-Body Problem on a cosmic scale. This makes God a ghost in the divine machine, separate from Creation in just the way humans have distanced themselves from Nature.
The notion of free will has traditionally depended on a concept of an immaterial self above the material laws of the universe, just as God is above them. The mechanistic view has gradually encroached on this notion, threatening to explain human behavior away as a mere cog in the machinery of matter, governed as strictly by causal laws as every other part of the cosmos. This is reflected even in jurisprudence, since it is unreasonable to hold a person responsible for their actions if these are determined by outside forces. This aspect of the M.B.P. becomes the search for a meaningful concept of free will and responsibility.
The mind-body split has influenced, and been influenced by, physical conceptions of matter and space. Without the metaphor of the container, there would be no inner and outer worlds. Without the metaphor of mechanism, there would be no abstract machine for the ghost to haunt. But what exactly gives us the idea of an inner space? Where is it located? To be sure, the body is sensed as containing a certain volume, and this is felt to be inside and to belong to us. But the body can also be experienced as external to the self as a pure point of consciousness. We identify with sensations such as pains, which seem engulfing in their urgency. At other times somatic sensations seem rather a part of the space contained by the body, a part of the physical world, surrounding and separate from the observer. The intimate or subjective senses are ambivalently experienced as qualities of the world or as bodily sensations. A certain flavor, for example, can seem to belong to whatever is tasted, but can also appear as a sensation in the mouth. This is manifestly not true of the distance senses. We inevitably experience seeing as taking place in the world outside the body, and never as a sensation on the body surface that the retina actually is. (Notwithstanding the painful sensitivity of the eyes to intense light, which is due to receptors connected with the diaphragm and not with the processing of a visual image). Under particular conditions (for instance on the threshold of pain), sounds may appear to be sensations in the ear, but normally they are perceived unequivocally as qualities of the world, localized in external space. The very idea of inside and outside originates in this difference between the near and the far senses. We are highly identified with the latter, and convinced of the objective physical world they convey. Through their ambivalence, the intimate senses, on the other hand, introduce the idea of subjectivity and cast doubt on the objectivity of the far senses. One could, however, turn the question the other way around and consider the puzzle (and the wonder!) of the illusory dimensionality and externality of space. How is it, in other words, that we see and hear things in the world rather than in our heads?
In the right conditions, the sense of touch can also be experienced as projected in space.  A tiny vibrator is applied to each of two fingertips on a person's hand. The rate of vibration of each stimulus can be varied independently, and the two can be coordinated so that the delay between them is slowly varied. When they are very much out of phase, the person feels separate sensations in the two fingertips. If the delay is reduced to a certain interval, the sensations fuse and are at first localized in the finger receiving the first impulse. But as the delay is further reduced, the feeling of the stimulus moves into and across the space between the fingers! Vision and hearing-- the projective spatial senses par excellence-- similarly involve the analysis of frequencies and the comparative inputs of two sources.
Since any mental event enters awareness in a sensory-based form-- that is, as an image of the world-- it is not surprising that imagination takes place in an interior space. "Thinking" is a catchword for a broad range of mental activities, of which deduction and induction have been abstracted as formal techniques. But even such formalisms are in certain respects spatialized--as, for example, in the mathematical idea of vector space or the Venn diagrams of set theory. As Kant maintained, the experience of space may be so primary that it is the condition for all other experience. Even pure consciousness-- without contents-- is sometimes described as an experience of empty space.