Getting the phone rooted doesn’t do much good as it only allows user to do more things that could be done without root like changing/moving files in the system to see emojis. A mobile is just like computer having partitions and folders. Now when then official OTA update arrives, it first checks the partition holding boot image and recovery image are unmodified.
You should learn to reset flash counter and also to remove binary flag as these may be hindering in updating your device. It is an easy process but considering the fact that it may damage your device, it becomes important to have good know-how of the process.
Understand your present situation and act accordingly. For this, you have to switch off your phone and press Volume down, home and Power button. Press Volume up as soon as you see the warning and now you will reach Download Mode. See the message on upper left corner of your Samsung Galaxy that you have. You can proceed further if it is Custom in Current Binary and After the Current Binary Download it gives a Yes.
Now reboot your phone and meanwhile visit this link to download TriangleAway present somewhere at the bottom. Read the information and check across if your device is available in the list of supported devices. Now that you have downloaded TriangleAway, you can transfer it to your device and begin installation. Once you start installing, it will ask for SuperUser permission, allow it.
See that the Current Status is same as it was during Download Mode. If you are all set to start press Begin else press Reset Flash Counter in case it checks out. Now wait for the app to act and your device will soon notify you when the flash counter is reset and reboot.
Next, go to Download mode and once again check the upper left corner to find the Customer Binary Column to set it to No and to Set Custom Binary to Samsung Official. If you have successfully done the procedure above that means TriangleAway has done its work and henceforth you will be receiving OTA updates after your phone boots.
Now in case this aforementioned process doesn’t work on your phone, what you can do is to flash the stock firmware and then wipe the data soon after the procedure. In order to check if your device detects as modified, follow these steps: Settings -> About Device -> Status -> Device Status.