This is common and nothing to worry about. Take tablet Zerodol-SP 1 tab 2 times a day for 5 days and do some neck exercises. Daily twice rotatory neck exercise for 5 mins will help you overcome this problem.
Next Steps
if problem persists consult a orthopedic
Health Tips
try to sleep without pillow for few days and see if tge pain improves