We evaluate quark number densities at imaginary chemical potential by lattice QCD with clover-improved two-flavor Wilson fermion. The quark number densities are extrapolated to the small real chemical potential region by assuming some function forms. The extrapolated quark number densities are consistent with those calculated at real chemical potential with the Taylor expansion method for the reweighting factors. In order to study the large real chemical potential region, we use the two-phase model consisting of the quantum hadrodynamics model for the hadron phase and the entanglement-PNJL model for the quark phase. The quantum hadrodynamics model is constructed to reproduce nuclear saturation properties, while the entanglement-PNJL model reproduces well lattice QCD data for the order parameters such as the Polyakov loop, the thermodynamic quantities and the screening masses. Then, we calculate the mass-radius relation of neutron stars and explore the hadron-quark phase transition with the two-phase model.