The reason why science has a hard time dealing with consciousness is because they are mistaking their abstractions with reality. It is called the fallacy of misplaced concreteness.
What scientist have done is abstracted away essential parts of reality for understanding consciousness. That is, they view the world as being composed of lifeless mechanical particles, and they do this because its useful in making predictions, such as in chemistry, but then they elevate these useful abstractions as being reality itself, which creates questions as to how can life and consciousness exist?
The truth is that the components of our consciousness exist in matter. How would you tell a man is conscious? He responds to you. In this way also, matter itself responds to stimulation, showing an awareness, showing a preference (magnetism for example), showing consciousness, maybe not the same consciousness as us, as we have an expanded and integrated awareness.
I'd recommend, if you have time, to watch this video: