In this paper, we investigate a (3+1)-dimensional generalized variable-coefficient Kadomtsev-Petviashvili equation, which can describe the nonlinear phenomena in fluids or plasmas. Painleve analysis is performed for us to study the integrability, and we find that the equation is not completely integrable. By virtue of the binary Bell polynomials, bilinear form and soliton solutions are obtained, and Backlund transformation in the binary-Bell-polynomial form and bilinear form are derived. Soliton collisions are graphically discussed: the solitons keep their original shapes unchanged after the collision except for the phase shifts. Variable coefficients are seen to affect the motion of solitons: when the variable coefficients are chosen as the constants, solitons keep their directions unchanged during the collision; with the variable coefficients as the functions of the temporal coordinate, the one soliton changes its direction.