Yes, It is illegal to impersonate someone on a profile in many countries. It is also against the terms of service of Facebook. If you are found guilty of profile impersonation, then your account will be banned. Moreover, if you are facing this issue, then you should report it to Facebook and also file a police complaint.