I'm relly no expert there, so dont think that what I say is neccessarily correct, but it seems to be the general question how a neural network work, so you might want to read up on that(
https://en.wikipedia.org/wiki/Artificial_neural_network). In general it tries so simulate the way a human brain works. Some go realted neural network usualy gets 19x19 "neurons" and has interconnections between them, that get more or less important as the net evolves and learns which connections between the intersections on the board are important and which arent.
If you do it a little more carefully, you probably have more than one layer with 19x19 neurons, so that not only the positions of the Stones(black/white/none) can be input, but also proprocessed information(can you capture there/is there a ladder there/ is a move there lagal), so that the net doesnt have to learn those things on its own(for example figuring out the rule "if that move captures a lot of stones, its probalbly good", is much easier to implement if you get an input point that tells you "capture here" and you dont have to combine the stones postion to find that out on yourself without someone telling you the capture rule).
At least AlphaGo has two of those nets, one to prdict, where the next move might be, and one to predict, who is likely to win, I suppose its the same with Leela, the first one being responsible for "NetProb"(how likely does it think a next move there is), the other one for "Net Win"