What is the basis for interaction with the brain? Is it dangerous for health?

That's right, but only you're talking about invasive interfaces. These are such, for work with which you need to open the skull)
Our neurointerface noninvasive sensors Slack touch the skin and are absolutely safe!