I found a Java code of a simple blockchain, isn't hard to find this kind of information, you only have to go to google and search what are you looking for
![Wink](https://bitcointalk.org/Smileys/default/wink.gif)
I will leave here the link:
https://www.baeldung.com/java-blockchainTo build your own blockchain you have to understand some concepts like Blocks, Nodes, Transactions and Mining.
It's simple to have a blockchain without nodes, the complex part came when all the nodes have the same information, so, good luck with your project.