The signal measured by fMRI is definitely related to neural activity, but the relationship is indirect and sometimes subtly complicated.
Neurons compute and communicate electrochemically by controlling how ions (charged particles) flow across their membranes. At "rest", the inside of a neuron is slightly negative (- 70 mV) relative to its environment. However, its surface is studded with channels that let different types of ions into/out of the cell as well as "receptors" that can open or close these channels. Some are opened by specific chemicals, which can bring the cell's membrane potential closer to zero (e.g., by admitting sodium ions). Once it gets above about -55 mV, other channels that are sensitive to voltage take over, and produce a wave of activity that shoots down the axon and eventually causes the release of chemicals that affect other neurons, muscles, etc. This is what actually does work in the brain, but it's not what fMRI measures.
Instead, fMRI exploits the fact this process is energetically expensive: neurons need oxygen and sugar (glucose) to do all that work, and so neurons need to plumbed into the vascular system so those can be delivered. The signal fMRI measures is called the BOLD signal, for Blood Oxygenation Level Dependent. The magnetic properties of a blood molecule carrying oxygen are a bit different from a deoxygenated one, and thus they can be told apart with some clever physics and signal processing.
Based on what I said above, you might expect that fMRI thus measures the reduction in oxygenation, but it actually turns out to be a lot more complicated than that. Levels do dip when nearby neurons are active, but only briefly. After that, they shoot up, above baseline levels: more blood--and more oxygen--are delivered to the formerly-active area.
This is mostly what fMRI measures. The neuromuscular coupling seems to vary between brain states and maybe even brain areas; it's affected by different health conditions and drugs too. It's also limited by the structure of the vascular system. People occasionally find that veins appear to be heavily involved in cognitive tasks, sometimes even more than the brain itself, but that's just because they're delivering the blood.
Despite all this, the mechanisms are getting better understood and you can certainly interpret a BOLD change as suggesting that something is happening in that particular region, even if it's not clear exactly how it's implemented.