apt autoremove or apt autoremove --purge
if your boot partition near full , those commands won't help you delete old version kernel
I Just try it and test it
when you install pve by ISO file, boot partitation only has 512MB (no any option can adjust it)
it'll cause a problem , can't save too much old kernel version , due to kernel Getting bigger
when you do system upgrade , it'll keep few old kernel...