Welcome to the forum.
That's quite enough. In fact M2 would also be OK, if you want to save $100 for other options. Or look for second hand machine (but may be hard to find with enough storage and memory)
- 256 GB storage is not enough.
Not enough. That's the most critical.
System will use close to 100 (even more in some cases) ; Xcode uses a lot of storage.
So 512 is a strict minimum, and 1TB is a safer choice for +$460 (personally I never go now below 2 TB).
Take care, that cannot be expanded. If you intend to keep your Mac for several years (more than 5 or 7 is a safe bet), you should consider 24 GB (extra $230)
- Mind also of screen size if you do not plan to buy an external monitor. Xcode requires a lot of screen space to develop efficiently (and comfortably). So 15" is better