Local anesthetics like lidocaine work by blocking voltage-gated sodium channels; these channels are the biological basis of action potentials and therefore neurotransmission. Exposure to any typical axons in sufficient dose will completely block all neurotransmission down those axons, whether in the CNS or peripherally.
Although it's common to talk of local anesthesia "putting to sleep" some body part, there's very little in common with sleep (unlike general anesthesia, which, depending on the anesthetic agent, can sometimes share some features with sleep). Brain neurons are not merely "disconnected" from each other during sleep, instead, brain networks are in a different state of function, for example with cortical neurons sharing periods of activity and quiescence that produces the "slow waves" of slow-wave sleep.
Local anesthesics "leaking" into the brain is potentially a big problem when it happens. Hamilton, 1992, discusses the specific issue of local anesthetics ending up in the brain stem during eye surgery. Since the brain stem controls important things like breathing, stopping neural activity there is an emergency situation.
That said, when done properly, local anesthesia in the head is common and generally safe. Medical personnel performing local anesthesia need to be aware of the local anatomy where they are working to avoid off-target effects.
Local anesthetics as well as regional cooling have been used in neuroscience experiments (for example see Boehnke & Rasmusson 2001), in both animal models and humans, to create "temporary lesions" in the brain and investigate function of brain region. So, yes, if used in a targeted manner, local anesthetics can be used to temporarily interfere with local brain function without necessarily causing loss of consciousness.
Boehnke, S. E., & Rasmusson, D. D. (2001). Time course and effective spread of lidocaine and tetrodotoxin delivered via microdialysis: an electrophysiological study in cerebral cortex. Journal of Neuroscience Methods, 105(2), 133-141.
Hamilton, R. C. (1992). Brain-stem anesthesia as a complication of regional anesthesia for ophthalmic surgery. Canadian journal of ophthalmology. Journal canadien d'ophtalmologie, 27(7), 323-325.