Xcode is the main development environment for native apps on Apple platforms. It contains the Swift compiler, platform SDKs, Simulator, debugger, test tools, interface previews, and the signing workflow used to build an app.
Before installing it, make sure your Mac can run a compatible version of Xcode. Use the Mac App Store for the standard installation or Apple's developer downloads when you need a specific supported version. The download is large because it includes development tools and platform resources.
A beginner SwiftUI project needs only a product name, an organization identifier, the SwiftUI interface, Swift as the language, and a place on disk. Xcode generates a working app so that you can learn by changing one small part at a time.