Is there a particular folder where I need to keep the downloaded OS package? If yes, then which is the folder? If no then how do I specify the path to it?
Android keeps the downloaded package in cache partition, since data partition is supposedly encrypted nowadays which cannot be mounted by Android in recovery mode without supplying decryption key and there is no other partition big enough to store bigger files. Use root access to move the file into /cache. You may have to set appropriate permission on it as well.
What is the equivalent command for
pm install -r $PATH_TO_APK in case of OS updates?
The OS update occurs in recovery mode (a barebone OS) and the recovery may have a provision to allow automatic execution of commands. Android stock recovery (<3e>) reads /cache/recovery/command and executes them automatically. If it is TWRP v2.1 or above, the file is /cache/recovery/openrecoveryscript. Check their links to know more.
How do I boot a device in "recovery mode" as mentioned in point # 3, in the link?
My answer here has it covered.
Where are the boot and recovery partitions in the device? Does it vary from device to device? In one of the devices which I have with me, I don't see any /boot or /recovery folder? Does boot mean the / (root) folder?
They vary from device to device but you can find the cache partition mounted at /cache. Boot partition need not be mounted since all of its content is automatically loaded into memory during boot. You would have to search internet to find partition scheme for your particular device. Izzy's Q&A could help too.
No, boot doesn't mean / folder. It is not even a directory in reality but the root of the largest tree (file hierarchy) created and populated each time the Android boots.
In case the OS update fails due to some reason( the device shuts down during the update, there was issue in the update package etc)- does android ensure proper rollback and that the device is in a consistent state and no data is lost?
No, if recovery starts modifying the system partition and is interrupted, there is no going back. Even if the process completes normally, the boot process may get into trouble.
Finally, OS update/upgrade cannot be called silent at all since there is so much happening on the screen.