To expound on what meridian said, a target voxel is selected(generally as center mass as possible), and the bullets deviate from that line of fire by an amount based on your soldiers' aim/hit chance. If you are standing behind a log, if the bullets deviate downward, they hit the log, not you, which is exactly what partial cover is.