Is it alright to reapply to a PhD program you got rejected from if you work on your application?
Generally yes (with improvements). Consider emailing their admissions to make sure they don't have a policy against reconsidering applicants some time later.