Salutations JagdeepSekhon,
Thank you for taking the time to visit the Apple Support Communities! We understand that you have an inquiry regarding the amount of photos that can be stored and synced between iPhone and iCloud. We will be honored to assist you!
The number of photos that can be stored in iCloud and an iOS device depends on how much iCloud storage you have and how much device storage is available on the iPhone. It is also based on how you use your iOS device and iCloud storage. (e.g. A film maker would use more storage than a photographer who uses their device solely for photos. e.g. An avid movie fan would use more space than an avid music fan.) The number of photos, videos, etc. that can be synced and stored will vary on each individuals usage. If you reach or exceed your iCloud storage limit, just make space available. If you reach the storage limit on your iPhone, just make more space available by removing and/or transferring content to a computer to free up space.
Check out these articles below for more information.
What's the difference between device storage and iCloud storage?
How iOS and macOS report storage capacity
Manage your photo and video storage
Manage your iCloud storage
Here is additional information for you.
About iCloud Photos and My Photo Stream
Keep your photos safely stored and up to date on all of your devices
Have a wonderful day!