is 4gb ram and 128gb storage enough for beginner ios development ?
Xcode ram and storage requirement
doubtful. xcode is a memory hog and osx likes to cache apps in memory. xcode will gobble up 12gb+ with documentation, simulators, tools. if you use xcode's builtin git for a repo, it's will consume a huge amount of space as it seems to keep every change in minutia.
it will run but probably slowly and you'll end up creating a cron and running sudo purge every 15 minutes.
If I double ram to 8 is enough?
i'd say max out ram capacity. if 8gb is the limit, create a 20gb ram drive and move temp space, swap file and do work on there.
osx kernel is usually around 1.5gb to 3gb depending up on the load, xcode can be anywhere from 2gb+ without a project loaded.
If you just want to get started, 4 GB RAM and 128 GB storage will do but it will not be enjoyable as your project grows (and expect some sluggishness in the dev environment, especially in the visual designer). A machine with 8 GB RAM and 256 GB storage would be a better option and 16 GB RAM would be even better, as iPad_dev suggested.
My work 27" iMac (2014, i5) has 16 GB / 512 GB. However, my home laptop is a 12" MacBook (2016, m7) with 8 GB / 256 GB and, while it's no speedster, can run all of my dev tools decently.
Xcode is very efficient with memory. I just looked at my memory usage for a project with around 10,000 lines of code in it and it's using 334 mb of memory - the simulator is also running and is using 54mb.
So, even the smallest Mac memory wise is fine.
Note, this is all Apple Silicon, M1 processor.