In Edelman's grand theory of the mind, consciousness is a biological phenomenon and the brain develops through a process similar to natural selection.
As the brain forms, starting in the early embryo, neurons that fire together wire together. So for any individual, the microconnections from neuron to neuron within the brain depend on the environmental cues that provoke the firing.
Someday scientists will make a conscious artifact. There are certain requirements. For example, it might have to report back through some kind of language, allowing scientists to test it in various ways. They would not tell it what they are testing, and they would continually change the test. If the artifact corresponds to every changed test, then scientists could be pretty secure in the notion that it is conscious.