Definitely looks like dependency issue. First I see this apt-get output:
Loading new spl-0.7.6 DKMS files... Building for 4.9.0-6-amd64 Module build for kernel 4.9.0-6-amd64 was skipped since the kernel headers for this kernel does not seem to be installed. Then later I see: Selecting previously unselected package linux-headers-4.9.0-6-common. Preparing to unpack .../08-linux-headers-4.9.0-6-common_4.9.82-1+deb9u3_all.deb ... Unpacking linux-headers-4.9.0-6-common (4.9.82-1+deb9u3) ... <omitted> Selecting previously unselected package linux-headers-4.9.0-6-amd64. Preparing to unpack .../10-linux-headers-4.9.0-6-amd64_4.9.82-1+deb9u3_amd64.deb ... Unpacking linux-headers-4.9.0-6-amd64 (4.9.82-1+deb9u3) ... Selecting previously unselected package linux-headers-amd64. Preparing to unpack .../11-linux-headers-amd64_4.9+80+deb9u4_amd64.deb ... Unpacking linux-headers-amd64 (4.9+80+deb9u4) … <omitted> Setting up linux-headers-4.9.0-6-common (4.9.82-1+deb9u3) ... Still present in 0.7.6-1~bpo9+1.