There are two types of UI components in Java: heavyweight and lightweight.
A heavyweight component is a wrapper for something that exists in the operating system. Windows as an operating system has methods to create windows, dialog boxes, etc.
A lightweight component is created entirely within the application using 2D drawing APIs and the like. The operating system knows nothing about it.
The two "official" Java GUI APIs are Swing and AWT. AWT is usually used by applets (early ones anyway). It consists of heavyweight components. Swing is built on top of AWT but is a far more extensive API for designing usually desktop applications. Most Swing components are lightweight.
So a Java desktop application may consist of one or more heavyweight components, probably with some lightweight components thrown in. Or it might be all lightweight components if the 2D drawing APIs are sufficient to "fake" Windows without a heavyweight component.
The frame you see around a Java application might be drawn their with a library like Java2D (either directly or via components that use that or a similar API) or it might be created by Windows with configuration from the application, probably affected by the operating system's theme and display settings.
Most Java applications these days are lightweight.