# What is the meaning of the “PRIMCELL.vasp” file generated by VASPKIT tool during bandstructure inputs generation?

When I use VASPKIT tool to generate K-path KPOINTS file for Bandstructure calcualtion of a 4x4x1 supercell of a pure material, it gives a PRIMCELL.vasp file (which contains the unit cell of that material) and asks me to replace my original supercell with it. BUT, when I use VASPKIT with a doped supercell structure, the PRIMCELL.vasp file keeps the structure a supercell and doesn't convert it to a unit cell.

Could you please tell me what the meaning of that file ? and what's the difference between the two procedures ?

I have never used VASPKIT, so my answer is of a general nature.
If you have a $$4\times4\times1$$ supercell of a perfect crystal, you have redundant information because you could always rebuild the supercell starting from the primitive cell by applying a supercell matrix. My guess is that the PRIMCELL.vasp file simply contains this primitive cell as a computer code will normally want to use the primitive cell, because calculations are cheaper.
If you first build a $$4\times4\times1$$ supercell of a perfect crystal, and then add a defect into the system, your new system can no longer be described as a supercell of a smaller primitive cell. I imagine this is the reason why in this case the PRIMCELL.vasp file does not contain a smaller cell: no smaller cell exists that can be transformed into your actual defect cell, so you have to do your calculations in the larger defect cell.
I assume that you are considering 2D materials. In short, you can use the undoped primitive cell to generate a k-path to plot the band structure of your $$4\times4\times1$$ supercell with doping.